Tabs - accessing new by index

Tabs - accessing new by index


I am trying to access and remove a tab that was created dynamically.
It works fine in FF but in IE a -1 is returned for the index,
indicating that it was not found.
function showInsurance(action){
    insuranceIndex = $("#tabNav a").index( $('a[href=#insurance]') )
    if(action == "show" )
    {
        if (insuranceIndex == -1)
            $('#container > ul').tabs('add', '#insurance', 'Insurance',$
('#container > ul').tabs('length') - 1);
    }
    else{
        $('#container > ul').tabs('remove',insuranceIndex);
    }
}















    • Topic Participants

    • mark