Even if vB5 utilizes a powerful Navigation Manager, it lacks the automation procedure for adding a Tab using a product file like version 4.2. In this tutorial I'll try to show you a way to add a Tab in the Nav Bar.
There are only 2 steps to do it:
1.- Adding the Tab (CODES section)
Christos Teriakis
There are only 2 steps to do it:
1.- Adding the Tab (CODES section)
2.- Assign the Phrase (GLOBAL section)<code version="1.0.0">
<installcode><![CDATA[
$assertor = vB::getDbAssertor();
$navbar = $assertor->getRow('site',array('siteid' => 1));
$array = unserialize($navbar['headernavbar']);
$newarray = array();
foreach($array as $key => $value){
$newarray[] = $value;
}
$newarray[] = array ('title' => 'navbar_mytest', 'url' => 'mytest.php', 'newWindow' => 0 );
$assertor->update('site', array(
'headernavbar' => serialize($newarray)
),
array('siteid' => 1)
);
]]></installcode>
<uninstallcode />
</code>
Hope that this short code will helps you in case that you want to move your mods to vB5 Connect.<phrase name="navbar_mytest" date="1350240918" username="vb5admin" version="1.0.0"><![CDATA[My Test]]></phrase>
Christos Teriakis