views:

32

answers:

2

Hello everyone!

I'm using jquery to create a tab-based featured content area on my website - http://www.gregmalkin.co.uk - but am having trouble getting the first tab to be 'active' on load, and then the active state to change to the selected tab when it auto changes.

When I click on a tab it becomes active, but I want them to be set as active automatically.

thanks in advance!

A: 

Maybe forcing the click on the pageLoad or in $(document).ready()??

function pageLoad(){
    $('#tabidtoset').click()
}

$(function(){
    $('#tabidtoset').click()
})

If you need the diferences between each one, read here

I just checked that tab plugin, and set active on the one you want to see first should work.

class="tabSelect active"
NicolasT
+1  A: 

I assume this tab plugin is pre-made? Try just adding "active" to the class of the first tab from its source.

<li><a rel="0" class="tabSelect active" href="#Tab0">Tierra Latina</a></li>
Tyler