richy96
06-05-2011, 11:31 AM
Hi
I'm using the following code to parse forum text.
This is in a VBa CMPS module I have written that displays from selected forum posts in a list of 'Whats Occurring' on my site home page
require_once(DIR . '/includes/class_bbcode.php');
$bbcode_parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list(),true);
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse($occuredUser[$i]['announcetxt'], $forum['nonforum'], true);
It works in as much as it parses the BB code like text colour, bold, italic etc
However it does not Parse smilies (they just don't show up when the parsed text is output)
Smilies are enabled on my site and work in forums, PMs etc
What am I doing wrong?
Cheers
Rich
--------------- Added 1307283641 at 1307283641 ---------------
Had a play a bit further but still can't sort this myself
In Vbulletin OPtions -> BB Code Settings
Allow Smilies in Non Forum Specific Areas = Yes
I also tried the following as it seemed promising...
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse($occuredUser[$i]['announcetxt'], 'nonforum', true);
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse_smilies($occuredUser[$i]['announcetxt'], true);
Got me nowhere. :eek:
Parsed text OK, no smilies still - and a headache coming on :confused:
I'm using the following code to parse forum text.
This is in a VBa CMPS module I have written that displays from selected forum posts in a list of 'Whats Occurring' on my site home page
require_once(DIR . '/includes/class_bbcode.php');
$bbcode_parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list(),true);
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse($occuredUser[$i]['announcetxt'], $forum['nonforum'], true);
It works in as much as it parses the BB code like text colour, bold, italic etc
However it does not Parse smilies (they just don't show up when the parsed text is output)
Smilies are enabled on my site and work in forums, PMs etc
What am I doing wrong?
Cheers
Rich
--------------- Added 1307283641 at 1307283641 ---------------
Had a play a bit further but still can't sort this myself
In Vbulletin OPtions -> BB Code Settings
Allow Smilies in Non Forum Specific Areas = Yes
I also tried the following as it seemed promising...
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse($occuredUser[$i]['announcetxt'], 'nonforum', true);
$occuredUser[$i]['announcetxt'] = $bbcode_parser->parse_smilies($occuredUser[$i]['announcetxt'], true);
Got me nowhere. :eek:
Parsed text OK, no smilies still - and a headache coming on :confused: