View Full Version : Making a certain text box render BBcode.
SnakeXs
05-11-2008, 01:48 PM
Pretty simple issue. I have a special "preview signature" mod in a mod approval system, but currently the field doesn't render the BBcode when previewing. How can I fix that? Rendering HTML isn't an issue, I'd even prefer it not to.
Thanks.
Opserty
05-11-2008, 07:17 PM
You'd need to run it through the vBulletin BBCode parser. Parse BBCode (in 3.5) (https://vborg.vbsupport.ru/showthread.php?t=82693)
SnakeXs
05-11-2008, 09:54 PM
You'd need to run it through the vBulletin BBCode parser. Parse BBCode (in 3.5) (https://vborg.vbsupport.ru/showthread.php?t=82693)
Is it advisable to use that with 3.7?
I gave it a test go, and it seems to parse the BBCode, but not the images.
if ($signature)
{
require_once(DIR . '/includes/class_bbcode.php');
$parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());
$parsed_text = $parser->parse($text);
It's simply parsing any images as links, and not displaying the images, which is the majority if what it's needed for.
Many thanks.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.