PHP Code:
function vbet_parseTitle(&$title, $removeNotTranslateSection = false, $andUunhtmlSpecialChars = true) {
global $vbulletin;
$tag_list = array();
$tag_list['option']['langtitle'] = array(
'callback' => 'handle_external',
'external_callback' => 'vbet_handle_bbcode_langtitle',
'strip_empty' => true,
'stop_parse' => true,
'disable_smilies' => true,
'disable_wordwrap' => true,
'strip_space_after' => 0
);
$parser = new vB_BbCodeParser($vbulletin, $tag_list, false);
$result = $parser->do_parse($title, 1, 0, 1, 0, 0, 0);
unset($parser);
if ($removeNotTranslateSection) {
$start = 0;
$result =& vbet_replaceFirstOffset('<!--vBET_SNTA--><!--vBET_NRE-->', '', $result, $start);
$result =& vbet_replaceFirstOffset('<!--vBET_ENTA-->', '', $result, $start);
if ($andUunhtmlSpecialChars) {
$result =& unhtmlspecialchars($result, true);
}
}
return $result;
}