![]() |
New tab not staying selected
When I create a new tab using the Navigation Manager it highlights when I click on it but when the new page opens the previous tab (home, forum, what's new) is highlighted as selected. The new tab does not stay selected after the page opens.
Has anyone else experienced this problem? How did you get around it? |
Can we see an image of your settings for the tab in the Navigation Manager?
|
The settings are as follows:
Active: Yes Product: vBulletin Title: Services Target URL: I set this to my new page which it opens ok Display Order: 50 Show Permission Name: I leave this as blank Append Tabid to URL: No Tab Scripts: This is blank Try it yourself. Add a new tab to open a new page then start up your site on one of your existing pages , then click to the new page tab and see if it stays selected and highlighted |
You need to enter something for the Tab Scripts. That is the THIS_SCRIPT name at the top of the php page. Or, if you have no THIS_SCRIPT, you just need a plugin to set the $root variable. Example for a forumdisplay page used as a navtab:
hook - set_navigation_tab_main PHP Code:
|
ok...that worked. But a second issue developed. I have two new tabs that call the same php file with different parms.
When I set both tabs with the same script name the first one always is set as selected even after I click on the second one. To get around this I created a clone of the php and put a suffix of "2" at the end of the file name and the script name in the cloned php Then I added the suffix to the script name in the second tab. Now everything works. Cloning the php file is not an elegant solution by any means but it does work and is the only solution I have right now. Thanks for the info |
Is this a vbulletin file, or a custom file ?
|
I'm adding custom pages using this mod:
https://vborg.vbsupport.ru/showthread.php?t=235359 I posted the detailed solution in the mod comments. It's ugly but it solves the problem. |
The way to solve it would be to write a plugin like I was showing in post 4 based on THIS_SCRIPT and the parameter that is passed.
|
I figured there was a better way to solve the problem then what I came up with.
|
Quote:
If on the same top level domain I want to set the tab to display e.g. the members list, or the calendar, then what script would I add here to get the tab to pull up a particular calendar or the list? PS: I know that if I put in /calendar in the URL box in the navigation manager then the calendar will come up, but the forum tab remains selected. So I'm guessing the answer is the same I need to put a script in the script box for the new 'calendar' or 'members' tab to remain highlighted. So which one for calendar, which one for members list? |
If it's a navtab, not a link/menu item, then you need to add something to the Tab Script(s) textarea to get it to stay (or do a plugin like I wrote). For the calendar, if you look at the top of that file, you'll see this:
HTML Code:
define('THIS_SCRIPT', 'calendar'); |
Ok, managed to solve almost all my tabs to stay highlighted except for this one:
An external app for links. harleyforum.se/links/index.php is the path. If i put the word index in script field it messes up, obviously. What should I put there? https://vborg.vbsupport.ru/external/2012/05/6.jpg |
Well, does the file have THIS_SCRIPT defined at the top of it?
|
Quote:
--------------- Added [DATE]1338413625[/DATE] at [TIME]1338413625[/TIME] --------------- However it does not work, first time I click the tab it works, but as soon I go back and click the forum, blog or article tab, it cant find that page, it points forum to mysite.se/links/forum, but should be mysite.se/forum only? This is my forum tab, default, if it helps you. https://vborg.vbsupport.ru/external/2012/05/5.jpg |
If your other tabs are not working, then there is another issue going on.
|
They are working fine UNTIL i put the links_index in script field for the links tab.
|
Are you sure that is the correct thing to put there? And when you say they are not working fine, what about them isn't working? We need more detail in order to help.
|
I have this same issue with a tab for my PhotoPost vBGallery. The only difference from other tabs is that the target URL is in a directory under public_html instead of being in the forum directory.
There are two issues.
|
We cannot help troubleshoot tab issues without seeing your settings.
|
I was using the Navbar Tabs Manager prior to v4.2.0 being released, so I understand all about the script names, etc.
I've removed that product so I can use the native Navigation Manager built into v4.2.0 but the problem I am having is that I cannot add all the script names needed for each tab because their is a limit of 30 characters on this field. Is there a way to overcome this limitation? For example, my Forum navtab lists the following tab scripts - index.online.private.search This means that when viewing who's online, private messaging, viewing new posts, etc that the Forum tab stays highlighted and the links underneath remain visible. But when reading a thread (showthread) or viewing the forums (forumdisplay) the tab is no longer highlighted and therefore no link options remain making navigation less friendly. I'd just like to make the tab scripts line read - index.online.private.search.showthread.forumdispla y - but I can't because for some reason this field was limited to 30 characters? |
Quote:
I ran across this with one of my mods and when I removed the underscore from the name it worked without a problem. |
1 Attachment(s)
Quote:
See attached. |
Yes, same setup/problem I have with underscore title. Only a cosmetic thing so not relly important. Tab still works.
|
Quote:
PHP Code:
Quote:
PHP Code:
|
Thanks, Lynne. I will give that try tonight.
|
Quote:
But are you saying that if we need to enter more than 30 characters we need to enter it by manipulating vBulletin code instead of via the interface provided? This is obviously a bug or, at the very least, an oversight in design. Can we expect this to be submitted for resolution in a future release? However, the tab highlight is the least of my problems with the Navigation Manager. As another stated, it's simply cosmetic but it definitely should be fixed at some point. My real concern is the problem with the 404 error that occurs EVERY TIME when clicking other tabs after first visiting a tab that points to a URL that is not within the standard /forum path. You can see this happen at my site (lancisti.net) by first clicking the Photo Gallery tab, then clicking any other tab. You'll see that after clicking the Gallery tab, any other tab click results in the /gallery directory replacing the /forum directory within the URL. It also seems to somehow break the URL for the icon image in the announcement message at the top of the Gallery page. Do we need to create another thread to get some help on this issue? |
I would not call creating a plugin "manipulating vbulletin code". It is also an "interface provided" in the software.
As for 30 characters being a bug, you are welcome to enter it into the bug tracker if you feel that way. I don't feel it is a bug when it is so easy to just write a plugin to do what I want. And, as for the 404 errors, you probably have your URLs set to something like "mypage.php" instead of "/forumdir/mypage.php", so it is looking for the page in the directory you are in. You may want to read up on the different types of relative paths. |
Quote:
Quote:
Quote:
No worries. I'll find someone else capable of helping me. |
Quote:
Quote:
However, you are welcome to find someone else to help you. I'll stop responding to your posts since you don't find my responses helpful. |
Quote:
--------------- Added [DATE]1338598664[/DATE] at [TIME]1338598664[/TIME] --------------- Quote:
--------------- Added [DATE]1338599040[/DATE] at [TIME]1338599040[/TIME] --------------- Originally Posted by Lynne Quote:
Next! |
Quote:
http://tracker.vbulletin.com/browse/VBIV-15197 And the requestors resolution was... Quote:
|
Quote:
They could save themselves a LOT of grief and time in responding to customers with this problem if they simply changed the Nav Manager default values to include the "/forum/" path in front of each PHP file name. Not only would it reduce requests for support, it would also provide a clear example that would help users easily figure it out for themselves. Not everyone who uses this COMMERCIAL product is a PHP coder or works all day at a Linux command line for a living. I really don't understand companies who seem to have the Incredible Hulk's "Puny humans!" attitude toward those who provide their livelihood. Obtuse responses to support/enhancement requests are not only unhelpful, they run completely counter to a company's goals. |
Quote:
Sorry to say this but you come off as arrogant and rude and with this attitude you will not find many people that will be willing to help you out. |
Not my intent to be rude or arrogant and I apologize for coming off that way. But if you have a problem with people having opinions other than yours, then, well, you just have a problem I guess.
From my POV (as a customer), the arrogance is on the part of people who seem to get miffed when a person asks a fairly simple question and then gets aggravated with flip answers from an employee of the product's company. If I was in any way knowledgeable in PHP coding I wouldn't be asking such questions in the first place. Do you not believe that it's a company's responsibility to support their customers AND a users responsibility to provide feedback for product improvement? That's the way it is in the world that I live and work in. I know that this is a "volunteer" site and perhaps I was in error to have have expected any real support for my problems here. But vBulletin is not an open source product and people who have purchased it rightfully expect to receive adequate and useful support provided in a professional manner, especially when it's coming from one of the company's employees. I ALWAYS have a great deal of appreciation for those who are actually helpful. But telling me that I simply need to "write a plugin" or "read up" on something is far from helpful. I work with product developers on a daily basis so I understand that it's hard for coders to understand this. But it really is easier to provide a simple explanation of the fix needed and why/how the fix works. Educating users along the way is a far better support model than telling them that there's nothing wrong with the product/design and they are just not smart enough to use it. Wouldn't it have been easier to simply say: The default tab paths use only relative paths to their respective files. If you wish to have tabs that direct users to a URL outside of the default forum directory, you will need to edit all of the default tab paths to include "/forumdir/" before the filename. I would also add that anyone providing even semi-official support for the product should be charged with logging any and all such support requests for evaluation by the design team as future fixes or enhancements. The issues I've talked about here definitely should qualify in that regard AND should be quite simple fixes. But instead, I got: You PROBABLY have YOUR URLs set wrong. You should read up... Now, please explain this arrogance thing to me again. But no worries. I now understand that this really isn't the place to ask for vBulletin product support so I won't make that mistake again. Thanks for your input. Really. --------------- Added [DATE]1338658813[/DATE] at [TIME]1338658813[/TIME] --------------- Quote:
But just to add to this so others reading this thread get the full picture about this issue, one of the dev team members also posted the following there. Apparently it's not a complete fix. Quote:
Quote:
But enough complaining. I know this isn't the place for that. Just wanted to clarify for those who seemed to be offended by my remarks. |
Quote:
First of all I do not have a problem with people having other opinions than mine. Opinions are like you know what, everyone has one :D Anyway, all I wanted to say is that with the way you spoke to Lynne and to everyone else trying to help you, was way off base. Lynne is one of the most helpful persons around here and at vb.com. Whereas about the answer that you got, it was the correct one. It pointed you in the right direction. You could also try to help yourself first btw by doing a little search rather than complaining. |
Quote:
As for doing a search first, that's always my approach. How do you think I found this particular thread? It seemed to be the only one that even marginally addressed my problems. Do you think I just clicked on the first thread I found and posted my questions? Where else would you suggest I look other than perhaps at the forum at vBulletin.com (which I have also done)? My complaints only came after I tried more than once to ask questions in a reasonable manner and got responses I found to be unhelpful. As for the answers I received, are you saying that you consider "write a plugin" or "read up" to be "correct" answers? If so, then we'll just have to differ on that. Pointing one in a "direction" is hardly the same as providing an explanation with a complete and correct answer, (such as the one that I actually provided). I'll try not to trouble any of you experts here again with my silly little questions. Promise. |
Wow reading some of that hurt my head a little.
I think this is the right thread thought, We have awards and gxboxlive leaderboard mods enabled and added them using the navigation system on vb4.2 But when i click either the tab highlighted is always forum, how do i stop this and if its by code where do i put it. www.xboxplayers.com Many thanks for any help you can offer |
Check the pages and look to see what THIS_SCRIPT is set to and enter that as the Tab Script for the navtab.
|
OK done Lynne thanks that was easy,
Next one is the additional tab which is just a link to a part of the forum "game nights". I saw discostu's posts but dont really understand where I am looking for the set_navigation_tab_main and then where do i post the script PHP Code:
PHP Code:
the forum id is "6", dont understand "array", and the tab is "tab_ota1_544" As usual thanks for your help |
Hopefully i haven't made it too confusing in my previous post but just checking in does anyone know what/where i should be putting my perspective code.
Thanks |
All times are GMT. The time now is 05:36 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|