how to set custom tab in jquery ui and use with rails
        Posted  
        
            by Katyal
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Katyal
        
        
        
        Published on 2010-01-31T04:43:39Z
        Indexed on 
            2010/03/13
            11:05 UTC
        
        
        Read the original article
        Hit count: 188
        
ruby-on-rails
|jqueryui
I'm using jqueryUI for tabs on a page. I initialize it like below:
$("#tabs").tabs();
<div id="tabs">
    <ul>
      <li><a href="#tabs-4">Part A</a></li>
      <li><a href="#tabs-2">Part B</a></li>
      <li><a href="#tabs-5">Part C</a></li>
   </ul>
   <div id="tabs-4">
    .....
   </div>
   <div id="tabs-2">
    ....
   </div>
   <div id="tabs-5">
   ....
   </div>
</div>
I have 2 questions.
- How do I set the tab to be custom. say I want second tab to be shown first. - $('#tabs').tabs(2)does not work. i got that from this link
- Let say I click on a button inside tab1. Clicking on the button takes control back to an action and then control comes back to this page. When the control comes back...then is it possible to set a custom tab?. For example. in tab 1 I click something...go back to the action...and then I want to come back to tab 2. 
© Stack Overflow or respective owner