I am trying to enable disable jquery tabs using class/id rather than direct index number, the tabs are being generated dynamically so i cant hard code the index number.
I have tried using this and it works fine $("#tabs").tabs( "option", "disabled",[2])
but like i said i cant hardcode so i tried using class $("#tabs").tabs( "option", "disabled", [$("classname").index()] )
but this is not working.
What am i missing? I have looked into jquery tabs document and did not find any info on how to use class. Any help will be appreciated.
this is what worked for me
$("#tabs").tabs( "option", "disabled", [$("#classname").index()])