Quote:
Originally Posted by Chuck S we define the names of scripts yes and we use that in our code. |
My Bbulletin 4 navtab plugin code bellow:
if (THIS_SCRIPT == 'ppindex' or THIS_SCRIPT == 'showphoto2' or THIS_SCRIPT == 'search2' or THIS_SCRIPT == 'member' or THIS_SCRIPT == 'upload' or THIS_SCRIPT == 'uploadphoto' or THIS_SCRIPT == 'showgallery' or THIS_SCRIPT == 'showmembers' or THIS_SCRIPT == 'useralbums')
{
if (THIS_SCRIPT == 'cpindex' or THIS_SCRIPT == 'showcat2' or THIS_SCRIPT == 'subscriptions2' or THIS_SCRIPT == 'showmembers3' or THIS_SCRIPT == 'search4' or THIS_SCRIPT == 'member3' or THIS_SCRIPT == 'uploadproduct2')
{
if (THIS_SCRIPT == 'rpindex' or THIS_SCRIPT == 'showphoto' or THIS_SCRIPT == 'search3' or THIS_SCRIPT == 'showcat' or THIS_SCRIPT == 'subscriptions' or THIS_SCRIPT == 'showmembers2' or THIS_SCRIPT == 'member2' or THIS_SCRIPT == 'uploadproduct')
{
Chuck,
When adding new buttons to Vbulletin the new button plugin evaluates the page to determine if it should hightlight the tab. As you see above for my three new button plugins I have added code to determine which tab should be highlighted when a PP, CP or RP page is selected. Given that there are duplicate page names being used between PP, CP and RP I had to do some renaming. Otherwise I would have some PP, CP or RP pages that either highlighted two buttons or the wrong button.
In PP I had to rename showphoto and search, in CP I had to rename showcat, subscriptions, showmembers, search and uploadproducts. In RP I had to rename search and member.
I haven't tested all links so I might need to rename more. Is there another way to achieve what I need here?
Unless you have a more elegant solution for me, are all the additional references to 'this_Script' in your code in text files? Would I be able to track all them down and rename them? I assume I'm not the first person to run all three of your apps in VB4 with navabs for each of your apps.