User talk:Monchoman45/Archive 7

Hello
http://images.wikia.com/zammy/images/d/d7/Monchoman45.png 18:25, December 4, 2012 (UTC)
 * Legit --  Random Time  23:19, December 4, 2012 (UTC)
 * Slander

Chat hacks, chatmod icon
Hi, I've seen that the chat hacks place a chat mod icon next to the username of the chat mods of that chat. But they don't seem to appear on my Wiki's chat (KnB Wiki), it's an empty file. Is there a way to upload the file? 18:38, December 4, 2012 (UTC)
 * That was fixed in this revision a month ago. It's possible your cache hasn't been updated since, I would clear it and see if the problem persists.

Chat Features for APW
Hey, I am the founder of Anything Pirates Wiki, and I was wondering if you could help me out with a couple things.

1.Get a chatmod icon, a gold coin with a black m on it, i can make the pic.

2. Put on chat hacks and etc.

3. Help me enabled the emoticons, the coding i got from the website is in the page, but it came up as links.

Thanks for your time! Please respond soon with an answer!

21:21, December 4, 2012 (UTC)


 * I'm not familiar with the standard way of accomplishing that. You can ask an admin at the Call of Duty wiki, they've changed their mod icons and also can help with number 2 (which you'll probably need for this anyway).
 * You'll want to copy the code from MediaWiki:Chat-welcome-message to the page with the same name on your wiki. You don't have to copy their actual welcome message, just the stuff after the . Then copy everything from MediaWiki:Chat.js/load.js to the same page on your wiki. With that, you can put chat stuff in MediaWiki:Chat.js and it'll load for everyone. I suggest copying CoD wiki's options.js. You can either put that directly into MediaWiki:Chat.js, or put it in MediaWiki:Chat.js/options.js and just put   in MediaWiki:Chat.js. That'll let you use chat hacks, and a bunch of other things you might want.
 * The code you got was HTML. MediaWiki:Emoticons doesn't work that way, it just needs the url of the image (for example, for the first one on the page, you want just  instead of  ). If you replace all of those, they should work normally.

Coding
Hello, I am an Administrator from the Fairy Tail Wiki and I was wondering if you could possibly lend me some assistance? Is there any sort of CSS or JS coding that I could use to hide the "Discussion about XXX" section that appears at the bottom of articles when you enable the new forum feature. My wiki is considering using the feature, but we don't want to if we have to have those at the bottom of the page.


 * CSS . Do note, however, that using that wiki-wide could be a ToU violation. As far as I know hiding read more is not (or at least it wasn't the last time staff said anything about it, which was a very long time ago), and this is essentially the same thing, but for forums. So basically, if you're allowed to, that's how you would do it, but I have no idea whether or not you're allowed to.


 * Thanks so much!!! For now, for the sake of getting what I want, I'll just assume it isn't a ToU violation. >_>


 * To clarify, staff have said this code is not permitted to be used wiki wide. See 1 and 2.

Parse Error in ChatHacks.js
I just tried your ChatHacks for the first time. Except I haven't. There's a parse error that prevents the code from loading:

"Error: JavaScript parse error: Parse error: Unexpected token; token 3 expected in file 'User:Monchoman45/ChatHacks.js' on line 320"

(copypasted from Firebug)

My guess is it's because you use "default" as a property name. That's a reserved word.

Besides: Do you really have to use eval? --


 * *sigh* I think I've found the source of the problem: ChatHacks.js doesn't load because NoScript doesn't permit attaching scripts from an external window. I created a new FF profile without NoScript and could load ChatHacks.js without problems. --


 * This appears to work for me (even with NoScript enabled):


 * Unfortunately I have no theory why this works while everything else failed :( --


 * May I ask two questions about your code?


 * Why do you test for objects in the while-loop of Preparse. window.commands doesn't contain any objects. So where are they? Where do they come from?


 * As far as I understand your code, it consists of not one but two scripts. The first and shorter one opens the chat window and then loads the larger one that contains the actual chat-hacks. So why are these two scripts in the same file? And why does the loader part of your script load the entire global.js and the entire wikia.js instead of ChatHacks.js only? --


 * Objects serve as subdirectories. It's a better way to manage a set of related commands, without having to use a single function that is essentially a switch. There aren't any natively, but if someone wanted to expand it to include, say, commands for managing a log, they could do that.
 * I could split it into two files, but there's not really any point. It wouldn't necessarily break anything, but I wouldn't gain anything either.
 * Importing personal code pages allows people to use other scripts as well. If it didn't import /global.js or /wikia.js, people wouldn't be able to use Joey's multi PMs script.


 * Loading a large script of which 95% aren't needed on pages other than Special:Chat is wasteful. I'd split the script if I were you.


 * Loading the entire global.js and wikia.js on Special:Chat is also wasteful. If I were to write everything from scratch I'd offer a way for other scripts to subscribe instead. But I see your point about Joey's PM script. Changing anything about this is probably not an option anymore.


 * Do I understand you correctly, that you don't currently use these subdirectory objects in the while loop of Prepare? Does anybody? If not, you could simplify the whole thing substantially.


 * How about declaring all those aliases from the window.commmands object separately:


 * Then you could reduce Preparse quite dramatically:


 * And those odd "default" prorties and eval would be gone... :P