PDA

View Full Version : SQL BBCode


Adrian Schneider
01-25-2008, 09:18 PM
The SQL bbcode is extremely glitchy.

If you preview/edit it, then it actually renders it into the WYSIWG as formatted text and previewing or submitting will destroy your original code.

Dream
01-26-2008, 06:33 AM
Some of my members reported similar behavior. Isn't it a stock vBulletin problem?

Wayne Luke
01-27-2008, 12:20 PM
Some of my members reported similar behavior. Isn't it a stock vBulletin problem?
There is no SQL bbcode in a default vBulletin.

Adrian Schneider
01-28-2008, 06:06 AM
Any update on this? It's a major flaw when posting any SQL.

Marco van Herwaarden
01-28-2008, 06:16 AM
Never seen it destroy original code, what i have experienced is that (when using preview???) sometimes 2 extra /SPAN are somehow added outside of the box. This might affect layout after the SQL code but i have never seen it make any changes to the code itself.

Adrian Schneider
01-28-2008, 06:55 AM
SQL Query: (how to run queries (http://www.vbulletin.com/docs/html/maintenance_query))
UPDATE TABLE ohnoes;

^^ final result.

Progress / reproduction pictures attached.

Dream
01-28-2008, 12:15 PM
There is no SQL bbcode in a default vBulletin.

Oh nevermind, I thought he was talking about the preview button messing text in general.

Adrian Schneider
06-17-2008, 11:17 PM
Still an issue...

Opserty
06-18-2008, 06:14 AM
I get this too. :)

Paul M
06-18-2008, 10:22 AM
Sorry, but its likely to remain an issue for the moment. I have no idea who wrote it, or the time to investigate how it works. I dont know if anyone else has time. All I can suggest for now is that you dont use the WYSIWG editor to preview it. I know thats not ideal, but thats how it is for the moment.

Opserty
06-18-2008, 11:03 AM
Just in case, class_bbcode_alt.php has an array of tags to ignore when parsing for the WYSIWYG editor you could maybe add SQL to the array somehow. Might not work, but I saw it yesterday so just thought I'd mention it :D

Lizard King
06-18-2008, 11:25 AM
Just in case, class_bbcode_alt.php has an array of tags to ignore when parsing for the WYSIWYG editor you could maybe add SQL to the array somehow. Might not work, but I saw it yesterday so just thought I'd mention it :D
You saved me a lot of headache :) Thanks for the tip ;)

Boofo
06-18-2008, 12:06 PM
I think the SQL tags were were written by Xenon a long time back. I have no idea who has updated it here since then.

Paul M
06-18-2008, 03:00 PM
Just in case, class_bbcode_alt.php has an array of tags to ignore when parsing for the WYSIWYG editor you could maybe add SQL to the array somehow. Might not work, but I saw it yesterday so just thought I'd mention it :D
Thanks. I'll have a look at that in the next few days, if its that simple then it will get fixed.

Dismounted
06-19-2008, 06:43 AM
I've just had a look, and this might work (looked in 3.7 files though). Create a plugin at bbcode_create. Add this PHP:
if ($this->is_wysiwyg() AND (isset($this->tag_list['no_option']['sql']) OR isset($this->tag_list['option']['sql'])))
{
unset($this->tag_list['no_option']['sql'], $this->tag_list['option']['sql']);
}