code/template/helper/actionbar.php
public function render($config = array())
    {
        $config = new ObjectConfigJson($config);
        $config->append(array(
            'toolbar' => null,
            'attribs' => array('class' => array('k-toolbar', 'k-js-toolbar'))
        ));

        $html = '';
        if(isset($config->toolbar) && count($config->toolbar))
        {
            //Force the id
            $config->attribs['id'] = 'toolbar-'.$config->toolbar->getType();

            $html .= '<div '.$this->buildAttributes($config->attribs).'>';

            foreach ($config->toolbar as $command)
            {
                $name = $command->getName();

                if(method_exists($this, $name)) {
                    $html .= $this->$name(ObjectConfig::unbox($command));
                } else {
                    $html .= $this->command(ObjectConfig::unbox($command));
                }
            }

            $html .= '</div>';
        }

        return $html;
    }
public function render($config = array())
    {
        $config = new ObjectConfigJson($config);
        $config->append(array(
            'toolbar' => null,
            'attribs' => array('class' => array('k-toolbar', 'k-js-toolbar'))
        ));

        $html = '';
        if(isset($config->toolbar) && count($config->toolbar))
        {
            //Force the id
            $config->attribs['id'] = 'toolbar-'.$config->toolbar->getType();

            $html .= '<div '.$this->buildAttributes($config->attribs).'>';

            foreach ($config->toolbar as $command)
            {
                $name = $command->getName();

                if(method_exists($this, $name)) {
                    $html .= $this->$name(ObjectConfig::unbox($command));
                } else {
                    $html .= $this->command(ObjectConfig::unbox($command));
                }
            }

            $html .= '</div>';
        }

        return $html;
    }
public function render ( $ config = array ( ) ) { $ config = new ObjectConfigJson ( $ config ) ; $ config -> append ( array ( 'toolbar' => null , 'attribs' => array ( 'class' => array ( 'k-toolbar' , 'k-js-toolbar' ) ) ) ) ; $ html = '' ; if ( isset ( $ config -> toolbar ) && count ( $ config -> toolbar ) ) { //Force the id $ config -> attribs [ 'id' ] = 'toolbar-' . $ config -> toolbar -> getType ( ) ; $ html .= '<div ' . $ this -> buildAttributes ( $ config -> attribs ) . '>' ; foreach ( $ config -> toolbar as $ command ) { $ name = $ command -> getName ( ) ; if ( method_exists ( $ this , $ name ) ) { $ html .= $ this -> $ name ( ObjectConfig :: unbox ( $ command ) ) ; } else { $ html .= $ this -> command ( ObjectConfig :: unbox ( $ command ) ) ; } } $ html .= '</div>' ; } return $ html ; }
Render the action bar

@param   array   $config An optional array with configuration options
@return  string  Html
Render the action bar