title: jquery ui tabs - get loaded tab in load event
body: <p>I'm using jquery ui tabs (from ui version 1.9.2), and the tabs are loading remotely via ajax.</p>
  
  <p>In the API documentation (<a href="http://api.jqueryui.com/1.9/tabs/#event-load" rel="nofollow">http://api.jqueryui.com/1.9/tabs/#event-load</a>), it seems to suggest that I can get the index of a loaded tab this way:</p>
  
  <pre><code>$(".tabs").tabs({
      load: function(event,ui) { console.log(ui.tab.index());  }
  });
  </code></pre>
  
  <p>However, this doesn't work.  I get an error because <code>ui.tab</code> is <code>undefined</code></p>
  
  <p>When I console.log <code>ui.tab</code> I get the full URL of the tab that was just loaded, leading me to believe that <code>ui.tab</code> is not the kind of object I'm expecting it to be.  I also tried using <code>ui.panel.index()</code> but I get the same <code>undefined</code> error.</p>
  
  <p>I can get the index of an <code>activated</code> tab using the <code>activate</code> event and <code>ui.newTab.index()</code>, but that's not what I'm looking for.</p>
  
  <p>What am I missing? </p>