function init() { parent::init(); $this->js(true)->tabs(array('cache' => false)); $this->tab_template = $this->template->cloneRegion('tabs'); $this->template->del('tabs'); }
function render() { // add loader to JS events if ($this->show_loader) { $this->options['beforeLoad'] = $this->js()->_enclose()->_selectorThis()->atk4_loader()->atk4_loader('showLoader'); $this->options['load'] = $this->js()->_enclose()->_selectorThis()->atk4_loader()->atk4_loader('hideLoader'); } // render JUI tabs $this->js(true)->tabs($this->options); if ($this->position == "bottom") { $this->js(true)->_selector('#' . $this->name)->addClass("tabs-bottom"); $this->js(true)->_selector('.tabs-bottom .ui-tabs-nav, .tabs-bottom .ui-tabs-nav *')->removeClass("ui-corner-all ui-corner-top")->addClass("ui-corner-bottom"); $this->js(true)->_selector(".tabs-bottom .ui-tabs-nav")->appendTo(".tabs-bottom"); } if ($this->position == "left" || $this->position == "right") { $this->js(true)->_selector('#' . $this->name)->addClass("ui-tabs-vertical ui-helper-clearfix"); $this->js(true)->_selector('#' . $this->name . ' li')->removeClass("ui-corner-top")->addClass("ui-corner-" . $this->position); } return parent::render(); }
function render() { $this->js(true)->tabs($this->options); return parent::render(); }