Quote:
Originally Posted by Parture
Basically I want it to work like any link would work with its menu. Pretty simple. I just don't know what to put in for values for 'yourpage' and 'link.php' to make this happen or if it is even possible. For example, on your own site what would you put in for these values to make it work which I could try out also to see if it works for me too?
If it doesn't work then it doesn't work. Need to try something else: rewrite the code.
|
OK, I'll give you an example of what I did on my site and maybe it will help you figure out what you really want..
I have torrents offered on my site. I have a torrents.php page, and few forums for the torrents and some upload pages and stuff. So, I want to link to that page - torrents.php. So, I have "link.php" set to "torrents.php". And, I have THIS_SCRIPT defined as "TORRENTS" at the top of the torrents.php page. Since I also want it to show that link when they are in the two torrents forums, I included that in the condition also. So, I used this as my unique condition:
PHP Code:
if (THIS_SCRIPT == 'TORRENTS' OR in_array($GLOBALS['forumid'], array(x, y, z)))
As for my "unique_name", I just used "torrents".
This is the result on my site:
Attachment 106152
If all you want to do is add a link to one of the existing sub-menus (like before New Posts in the Forum tab), then you can either just modify the navbar directly or use an existing template_hook (in the example of before New Posts, then the "navbar_start" template_hook) just like you did in vb3. This tutorial is for adding a whole new tab with a sub-menu.