Version: , by s.molinari
Developer Last Online: Sep 2018
Version: Unknown
Rating:
Released: 07-21-2001
Last Update: Never
Installs: 1
No support by the author.
Ok, I'm not sure if this has already been done. I checked Kier's original hack and I searched for other possible hacks and didn't find any.
This hack or code improvement, as I would like to call it, helps out with the problem of the vBcode or smilies always being added to the end of the text in the textarea box. In other words no matter where you would like to add a vBcode or smilie it will always be placed at the end of the text written.
The new vbcode.js script below will fix this. With this improvement you could go any where in the text that you have written and add smilies or format the text in what ever way you would like. The added vBcode or smilie will always be inserted at the point where the cursor is.
Please note: You must add the following in the textarea tag for the message, otherwise the new script will not work. You'll find these textareas in the newreply and newthread templates.
Your new textarea tag should look like this(red code denotes the chages that should be made):
Can somebody tell me why I'm busting my a.. uh... brains training to get the script to work half ways on Nutscrape?
It's like pulling teeth. But I got it working or rather I got the bugs out.
Anyhow, for those interested, it now works with Nutscrape 4.X, albeit, as it always did. That means when you use Nutscrape the vBcode or smilies will always be appended to the end of any text already written.
If your using IE, then the script appends the smilies and vBcode wherever the cursor is. It is really nice because you can go back and easily go crazy reformatting your text or add smilies anywhere you'd like.
Again, Kier has the script and is giving it a look over. With any luck it will be released in vB2.0.2.
anyways....question: What happens if a user hits the more smilies option? Will it still place their smilie from the pop-up window in the place where the cursor was last?
I will echo that sentiment. With the amount of ink spent on this so far, the hack up instructions could have been written several times over.
Has anyone tried the new .js file with NS6? Of course those functions will not work with NS4; it does not implement the same methods and properties for text areas as does IE5. When the vBcode hacks first came out, I found an excellent comparison of the two that explained just this point, but I cannot locate it, now.
As far as I know, that is the only difference between the two browsers, though. (Just kidding, guys!)
freddie: js code is not secure. In fact, anyone can get it from your website here, http://vbulletin.com/forum/vscript.js Anyone know knows ANYTHING about web programming knows this. I also belive that kier has releaed this hack, before it was in the official vb code.
Mentor thanks for telling me what I already know. Feel free to grab the .js but remember that you cannot post the .php files and this sort of thread will give that idea to some people hence my actions.
Then instead of remove the file, simple post in bold leters on the very top of the thread, stating that you may not post the php files anywhere, but the js is an exception.
Originally posted by freddie Mentor thanks for telling me what I already know. Feel free to grab the .js but remember that you cannot post the .php files and this sort of thread will give that idea to some people hence my actions.
Hello Freddie,
Does what you said mean I have permission to post the script?