Opened 8 years ago

Closed 8 years ago

#7559 closed bug (worksforme)

loading default tab via anchor

Reported by: astagl Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.tabs Version: 1.8.14
Keywords: Cc:
Blocked by: Blocking:

Description

When the content divs aren't in the exact same order as the tabs order, it will select the proper tab, but load the content based by index I suppose.

For example:


<script type="text/javascript">
    $(document).ready(function() 
    {   
        $('#container-1 > ul').tabs();

    });

</script>

<div id="container-1">
        <ul>
            <li><a href="#1"><span>tab 1</span></a></li>
            <li><a href="#2"><span>tab 2</span></a></li>
            <li><a href="#3"><span>tab 3</span></a></li> 
        </ul>

        <div id="1">
              <span>tab 1 content</span>
        </div>

        <div id="3">
              <span>tab 3 content</span>
        </div>

        <div id="2">
              <span>tab 2 content</span>
        </div>
</div>

index.php#3 will select the #3 tab, but load the content for #2.

I'm sure someone is going to ask why I don't just put the content in the same order... I need to adjust the content for SEO purposes.

Change History (1)

comment:1 Changed 8 years ago by Scott González

Resolution: worksforme
Status: newclosed

This has been working fine since 1.8.6 (see #6125). The fact that you're calling tabs on the ul and not the div suggests that you're using a really old version.

Note: See TracTickets for help on using tickets.