如何使用jQuery禁用选项卡

问题描述:

我在主选项卡下有三个子选项卡,当我默认单击主选项卡时,我正在使用jquery网格显示tab1数据,现在最初需要禁用tab2和tab3。

I have three subtabs under main tab, when I click main tab defauly I am displyaing tab1 data using jquery grid, now initially I need disable the tab2 and tab3. how?

从jQuery UI选项卡文档。请注意,它是从零开始的,因此将禁用第二个和第三个选项卡。

From the jQuery UI tabs documentation. Note that it's zero-based so this disables the 2nd and 3rd tabs.

$( ".selector" ).tabs( { disabled: [1, 2] } );