Cjuitabs Showing Multiple Tabs In Content

Hi Everyone,

i noticed when adding "id" to CJuiTabs using the following format, some tabs render multiple tabs in the content rather than just the active one.

Here is the code:





$this->widget('zii.widgets.jui.CJuiTabs', array(

    'tabs'=>array(

        'Government'=>array('id'=>'Government', 'content'=>$govContent),

        'Manufacturing & Distribution'=>array('id'=>'Manufacturing & Distribution', 'content'=>$mfgContent),

        'Retail'=>array('id'=>'Retail', 'content'=>$retailContent),

    ),

    'options'=>array(

        'collapsible'=>false,

        'active'=>$tab,

        'show'=>'fadeIn',

   	

    ),

    'htmlOptions'=>array(

        'style'=>'width:910px; height: auto;'

    ),

        

    'themeUrl'=>Yii::app()->baseUrl.'/css/JuiTabs',

    'theme'=>'custom',

        

    'cssFile'=>'jquery-ui-1.10.1.custom.css',

));



If I use the format as below without the id, it works fine.





$this->widget('zii.widgets.jui.CJuiTabs', array(

    'tabs'=>array(

     	'Government'=>$govContent),

        'Manufacturing & Distribution'=>$mfgContent),

        'Retail'=>$retailContent),

        ...



Any ideas on what’s going on?

Thanks,

I figure it out and will post it for anyone who might have the same problem. It doesn’t like having a space in the ‘id’. Not sure why it is a problem since it is wrapped in single quotes.

I had to change the following code:





  'Manufacturing & Distribution'=>array('id'=>'Manufacturing & Distribution', 'content'=>$mfgContent),

to:




 'Manufacturing & Distribution'=>array('id'=>'Manufacturing', 'content'=>$mfgContent),