View Full Version : How can I change the BBCODE keyword color?
john7911
04-14-2013, 02:03 PM
Hi,
I have in my Forum a dark background, if I put an HTML or PHP code the key word color are not visible as shown in this picture:
http://imageshack.us/a/img202/3817/htmlib.png
My question is, is it possible to change the color?
Thank you.
Create a new plugin using hook bbcode_create and this code:
ini_set('highlight.keyword', '#ffffff');
of course you can change the #ffffff to whatever you want. Also, if you want to change anything other than the keyword, here's the list of things you can change: http://us2.php.net/manual/en/misc.configuration.php#ini.syntax-highlighting
Edit: I should have added, this will only change it for new posts, until the cached posts expire. If you want it to take effect for all posts immediately, you could truncate the 'postparsed' database table.
john7911
04-14-2013, 06:55 PM
Thank you ;)
you could truncate the 'postparsed' database table.
I have opened this table but I don't know how to do :( can you please give me more details.
Thank you :)
If you're using phpMyAdmin, it's on the Operations pages, Empty The Table (TRUNCATE). Be careful not to delete it.
Another thing I think would work would be to go to Server Settings and Optimization Options in the admincp settings, and set Cached Posts Lifespan to 0 (after first noticing what it's set to and remembering it), then under the Scheduled Task Manager, run the Hourly Cleanup #2 task. Then set the Cached Posts Lifespan back to it's original value.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.