flashfocus
06-14-2009, 07:58 AM
Hi,
I'm trying to implement this mod:
https://vborg.vbsupport.ru/showthread.php?t=93071&page=4
I've added the following:
if (!function_exists('handle_bbcode_xml'))
{
function handle_bbcode_xml(&$parser, $code, $type)
{
return handle_bbcode_highlight( $parser, $code, 'XML' );
}
}
$this->tag_list['no_option']['xml'] = array(
'callback' => 'handle_external',
'strip_empty' => true,
'stop_parse' => true,
'disable_smilies' => true,
'disable_wordwrap' => true,
'strip_space_after' => 1,
'external_callback' => 'handle_bbcode_xml'
);
So now I would be able to highlight XML using [highlight=XML] and [XML]. These both work. However, when I edit or quote a post with highlighted syntax, only the [highlight=xml] gets turned back into bbcode. The [xml] tag just displays the HTML it generated.
When I look in my database, the bb-code is still there, so why am I seeing the generated html in stead of the bbcode ?
https://vborg.vbsupport.ru/attachment.php?attachmentid=100554&stc=1&d=1244970036
All help is appreciated!! :)
I'm trying to implement this mod:
https://vborg.vbsupport.ru/showthread.php?t=93071&page=4
I've added the following:
if (!function_exists('handle_bbcode_xml'))
{
function handle_bbcode_xml(&$parser, $code, $type)
{
return handle_bbcode_highlight( $parser, $code, 'XML' );
}
}
$this->tag_list['no_option']['xml'] = array(
'callback' => 'handle_external',
'strip_empty' => true,
'stop_parse' => true,
'disable_smilies' => true,
'disable_wordwrap' => true,
'strip_space_after' => 1,
'external_callback' => 'handle_bbcode_xml'
);
So now I would be able to highlight XML using [highlight=XML] and [XML]. These both work. However, when I edit or quote a post with highlighted syntax, only the [highlight=xml] gets turned back into bbcode. The [xml] tag just displays the HTML it generated.
When I look in my database, the bb-code is still there, so why am I seeing the generated html in stead of the bbcode ?
https://vborg.vbsupport.ru/attachment.php?attachmentid=100554&stc=1&d=1244970036
All help is appreciated!! :)