public function testTabbableTabs() { $I = $this->codeGuy; $html = TbHtml::tabbableTabs(array(array('label' => 'Link', 'content' => 'Tab content'))); $tabbable = $I->createNode($html, 'div.tabbable'); $ul = $tabbable->filter('ul.nav'); $I->seeNodeCssClass($ul, 'nav-tabs'); }
$tabs[] = array('label' => Yii::t('info', 'Option'), 'content' => $this->renderPartial('_option', array('option' => $option), true, false), 'linkOptions' => array('class' => 'poption')); } if (isset($attribute)) { $tabs[] = array('label' => Yii::t('info', 'Attribute'), 'content' => $this->renderPartial('_attribute', array('attribute' => $attribute), true, false), 'linkOptions' => array('class' => 'poption')); } if (isset($image)) { $tabs[] = array('label' => Yii::t('info', 'Image'), 'content' => $this->renderPartial('_image', array('image' => $image, 'userImages' => $userImages), true, false), 'linkOptions' => array('class' => 'poption')); } if (isset($discount)) { $tabs[] = array('label' => Yii::t('info', 'Discount'), 'content' => $this->renderPartial('_discount', array('discount' => $discount), true, false), 'linkOptions' => array('class' => 'poption')); } if (isset($special)) { $tabs[] = array('label' => Yii::t('info', 'Special'), 'content' => $this->renderPartial('_special', array('special' => $special), true, false), 'linkOptions' => array('class' => 'poption')); } //$tabs[] = array('label' => 'Add Address', 'content' => '...', 'linkOptions'=>array('class'=>'add-ress caddress'), 'icon' => TbHtml::ICON_PLUS_SIGN); echo TbHtml::tabbableTabs($tabs, array('placement' => TbHtml::TABS_PLACEMENT_LEFT)); ?> <div id="pageinfo" class="hide"> <div id="createAdd"><?php echo $this->createUrl('createaddress'); ?> </div> <div id="labelAdd"><?php echo Yii::t('label', 'Address'); ?> </div> </div> <div class="hlinks hide"> <div class="uid"><?php echo $model->id;
<?php echo TbHtml::tabbableTabs(array(array('label' => 'Section 1', 'active' => true, 'content' => '<p>I\'m in Section A.</p>', 'id' => 'tabsLeft_1'), array('label' => 'Section 2', 'content' => '<p>Howdy, I\'m in Section B.</p>', 'id' => 'tabsLeft_2'), array('label' => 'Section 3', 'content' => '<p>What up girl, this is Section C.</p>', 'id' => 'tabsLeft_3')), array('placement' => TbHtml::TABS_PLACEMENT_LEFT)); ?> </div> <pre class="prettyprint linenums"> <?php echo TbHtml::tabbableTabs(array( array('label' => 'Section 1', 'active' => true, 'content' => '...'), array('label' => 'Section 2', 'content' => '...'), array('label' => 'Section 3', 'content' => '...'), ), array('placement' => TbHtml::TABS_PLACEMENT_LEFT); ?></pre> <h4>Tabs on the right</h4> <div class="bs-docs-example"> <?php echo TbHtml::tabbableTabs(array(array('label' => 'Section 1', 'active' => true, 'content' => '<p>I\'m in Section A.</p>', 'id' => 'tabsRight_1'), array('label' => 'Section 2', 'content' => '<p>Howdy, I\'m in Section B.</p>', 'id' => 'tabsRight_2'), array('label' => 'Section 3', 'content' => '<p>What up girl, this is Section C.</p>', 'id' => 'tabsRight_3')), array('placement' => TbHtml::TABS_PLACEMENT_RIGHT)); ?> </div> <pre class="prettyprint linenums"> <?php echo TbHtml::tabbableTabs(array( array('label' => 'Section 1', 'active' => true, 'content' => '..'), array('label' => 'Section 2', 'content' => '..'), array('label' => 'Section 3', 'content' => '...'), ), array('placement' => TbHtml::TABS_PLACEMENT_RIGHT); ?></pre> </section> <!-- Pagination ================================================== --> <section id="pagination">