PDA

View Full Version : wysiwyg to BBCode (and reverse)


markp_2000
03-27-2012, 04:30 PM
I'm updating a plugin to vb4.x from vb3.8 and I need a replacement for the following

$vbulletin->GPC['message'] = convert_wysiwyg_html_to_bbcode($vbulletin->GPC['message'], $foruminfo['allowhtml']);

I think the function came out of the functions_wysiwyg.php file.

Mark

kh99
03-27-2012, 06:31 PM
I think you want this:

require_once(DIR . '/includes/class_wysiwygparser.php');
$html_parser = new vB_WysiwygHtmlParser($vbulletin);
$vbulletin->GPC['message'] = $html_parser->parse_wysiwyg_html_to_bbcode($vbulletin->GPC['message'], $foruminfo['allowhtml']);

markp_2000
03-30-2012, 01:11 AM
Thanks! It worked like a champ.

Mark