View Single Post
  #1  
Old 09-10-2014, 05:35 AM
 
Martin Bishop Martin Bishop is offline
 

Advanced Member
  
Join Date: Sep 2011
Posts: 65
 

Default Selected tab - on page load

Anyone know how I would get the first ui tab to always but the one open when a page loads?

At the moment if I select say the 3rd tab on one product and then navigate to e new product then the page will open on the 3rd tab. I want each page to open on the 1st tab.

my uitabs.tpl currently shows this at the top which I guess may be controling this:

Code:
<script type="text/javascript"> //<![CDATA[ $(function() {ldelim} var tOpts = {ldelim} idPrefix: '{$prefix|default:"ui-tabs-"}', cookie: {ldelim} expires: 1 {rdelim}{if $selected}, selected: '{$selected}'{/if} {rdelim}; $('#{$prefix}container').tabs(tOpts); {rdelim}); //]]> </script>

and I've read a number of things which reference something like this as a way of selecting a specific tab:

Code:
$("yourSelector").tabs({ active: 2 });

but have absolutely no idea how to put the two together? anyone have any idea what I need to do?

thanks
__________________
4.4.3
Reply With Quote