Try something like this:
$tabs = $('#tabs').tabs({ cache: true }); var total = $tabs.find('.ui-tabs-nav li').length; var currentLoadingTab = 1; $tabs.bind('tabsload',function(){ currentLoadingTab++; if (currentLoadingTab < total) $tabs.tabs('load',currentLoadingTab); else $tabs.unbind('tabsload'); }).tabs('load',currentLoadingTab);
Initializes tabs with a cache parameter so that the tabs do not reload after they have been loaded once. Then it detects the total number of tabs and sets the next tab to load as 1 (indexes are indexed starting at 0) Then it binds the event in the load event to start loading the next tab until it hits all of them. To launch it, it loads the second tab.
PetersenDidIt
source share