Thank you very much Lynne,
I had to add a little bit more and actually change the plugin code to a simpler version.
Inside the plugin I had to create a third variable $new_banners and only pre-registered that variable within template and ran it through parse_templates hook
Quote:
$random_number = mt_rand(1, 5);
$random_banner[1] = '<img src="path/to/banner1.gif" alt="" border="0" />';
$random_banner[2] = '<img src="path/to/banner2.gif" alt="" border="0" />';
$random_banner[3] = '<img src="path/to/banner3.gif" alt="" border="0" />';
$random_banner[4] = '<img src="path/to/banner4.gif" alt="" border="0" />';
$random_banner[5] = '<img src="path/to/banner5.gif" alt="" border="0" />';
$new_banners = $random_banner[$random_number];
vB_Template: reRegister('navbar',array('new_banne rs' => $new_banners));
|
To make it work, I just dropped this code
{vb:raw new_banners} on the template and now it works just as before under vB3.x.
I appreciate your help and
borbole for helping me through this.
I hope other users find this little experience useful in their sites.