(c) 2016, Deluxe-Menu.com
Search  
Ctrl+F2 - enter/switch menu | Arrow keys - navigate | Esc - exit menu  
  Support
  FAQ
  Contacts
  About Us
  Recent Questions


 

    Can someone point me in the right direction to have the correct tab selected in the css tab menu..

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 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 in the css tab menu after i click it and goto the page.


A: Deluxe Tabs doesn't support API functions which can return the selected 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" 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>
</span>




Return to Recent Questions

Related:
Bootstrap Popover Button Bootstrap Modal Position  |  Bootstrap Input Validation  |  Bootstrap Collapse Toggle  |  Bootstrap Pagination Responsive  |  Bootstrap Buttons Group  | 
Copyright (c) 2019, Deluxe-Menu.com
Home  |  Product Info  |  Samples  |  Download  |  Purchase  |  FAQ  |  Site Map  |  Terms of Use  |  Write Us
All rights reserved. Free AI Website Builder | AI Website Generator | Free AI Website Generator | Website Generator AI | AI website design generator