public function add($title, $options = '')
    {
        if (!is_array($options)) {
            $url = $options;
            $options = array();
            $options['url'] = $url;
        }

        $options['parent'] = $this->id;

        return $this->builder->add($title, $options);
    }
public function add($title, $options = '')
    {
        if (!is_array($options)) {
            $url = $options;
            $options = array();
            $options['url'] = $url;
        }

        $options['parent'] = $this->id;

        return $this->builder->add($title, $options);
    }
public function add ( $ title , $ options = '' ) { if ( ! is_array ( $ options ) ) { $ url = $ options ; $ options = array ( ) ; $ options [ 'url' ] = $ url ; } $ options [ 'parent' ] = $ this -> id ; return $ this -> builder -> add ( $ title , $ options ) ; }
Creates a sub Item.

@param string $title
@param string|array $options
@return Item
Creates a sub Item .