Topic: Fancy Video Tag does not render videos.
I have problems with fancy_video_tag
PunBB v1.4.6 by Visman
Fancy Video Tag 0.4.11.2 by dimka.linux
It renders the text: ".fancy_video_tag_parse($matches[1])." instead of showing the videos.
It has in its manifest;
<hook id="ps_do_bbcode_replace"><![CDATA[
// ADD PARSER, EXCEPT SIG
if (!$is_signature) {
$pattern[] = '`\[video\]([^\[]+)\[/video\]`';
$replace[] = '".fancy_video_tag_parse($matches[1])."';
}
]]></hook>
It looks like it successfully matches the "video" tags, but instead of running the "fancy_video_tag_parse" function, it shows it as text
I managed to run it by changing the manifest to:
<hook id="ps_do_bbcode_replace"><![CDATA[
// ADD PARSER, EXCEPT SIG
if (!$is_signature) {
$pattern_callback[] = '`\[video\]([^\[]+)\[/video\]`';
$replace_callback[] = function ($matches) { return fancy_video_tag_parse($matches[1]); };
}
]]></hook>
Is this a good solution?