When I click on a drop down menu links tab and it links to another page it automatically highlights the first tab in the row..
Return to Recent Questions
Q:
I have setup some tabs on a site that I am designing and for some
reason when I click on a drop down menu links tab and it links to another page it
automatically highlights the first tab in the row. I have tried
fiddling with it and have not been able to figure it out. Can
someone point me in the right direction to have the correct tab
selected after i click it and goto the page.
A:
Deluxe Tabs doesn't support API functions which can return the
selected drop down menu links tab.
You can set "bselectedItem" and "var bselectedSmItem" parameters
based on your link before you call your data file.
For example, move "var bselectedItem" and "var bselectedSmItem" drop down menu links parameters
from your data file to your code.
<TD vAlign=top align=left>
/* Select Tab */
<script type="text/javascript" language="JavaScript1.2">
var bselectedItem=<?php echo $seltabs; ?>;
var bselectedSmItem=<?php echo $selsmtabs; ?>;
</script>
<SCRIPT src="data.js" type=text/javascript></SCRIPT>
</TD>
You should define seltabs and selsmtabs using server side script.
You can also set it on every page before you call data.js file, for
example:
<TD vAlign=top align=left>
/* Select Tab */
<script type="text/javascript" language="JavaScript1.2">
var bselectedItem=4;
var bselectedSmItem=3;
</script>
<SCRIPT src="data.js" type=text/javascript></SCRIPT>
</TD>
Try that.
Return to Recent Questions
Related:
- Sep 02, 2006 - Little vertical spacers between menu items in the drop down menu.
- Sep 06, 2006 - The alighment of the dropdown menu is off to the right in Firefox...
- Sep 06, 2006 - The first item of the html drop down menu stays highlighted.
- Sep 11, 2006 - How can I hide my dropdown menu on print?
- Sep 11, 2006 - If I use doctype the settings of the submenus in javascript dropdown menu get lost.
- Sep 16, 2006 - I need to be able to highlight the selected menu item of the html tree menu.
- Sep 22, 2006 - Where do I add my "blahblah.htm" page links in js menu?
- Sep 23, 2006 - Is it possible that javascript drop down menus doesn't put anything on the local computer?
- Sep 24, 2006 - If there is a way of establishing the width at "runtime" in the javascript dynamic menu?
- Sep 26, 2006 - Firefox doesn't support the dropshadow and effects in the javascript pull down menu.
- Sep 29, 2006 - Is it possible to use an external file in the java drop down menu?
|