src/View/Helper/HtmlHelper.php
public function link($title, $url = null, array $options = [])
    {
        $options = $this->addClass($options, $this->_class(__FUNCTION__));
        $options = Hash::merge([
            'escapeTitle' => false,
            'clear'       => false,
            'label'       => $title,
        ], $options);

        $isClear = (bool) $options['clear'];
        unset($options['clear']);

        $options = $this->_setTitleAttr($title, $options);

        //  Set title in html tag.
        if ($this->_isEscapeTitle($title, $isClear, $options)) {
            $title = $this->tag('span', $title, ['class' => $this->_class(__FUNCTION__) . '-title']);
        }

        $options = $this->_getBtnClass($options);
        $options = $this->_getToolTipAttr($options);

        list($title, $options) = $this->_createIcon($this, $title, $options);
        unset($options['label']);

        return parent::link($title, $url, $options);
    }
public function link($title, $url = null, array $options = [])
    {
        $options = $this->addClass($options, $this->_class(__FUNCTION__));
        $options = Hash::merge([
            'escapeTitle' => false,
            'clear'       => false,
            'label'       => $title,
        ], $options);

        $isClear = (bool) $options['clear'];
        unset($options['clear']);

        $options = $this->_setTitleAttr($title, $options);

        //  Set title in html tag.
        if ($this->_isEscapeTitle($title, $isClear, $options)) {
            $title = $this->tag('span', $title, ['class' => $this->_class(__FUNCTION__) . '-title']);
        }

        $options = $this->_getBtnClass($options);
        $options = $this->_getToolTipAttr($options);

        list($title, $options) = $this->_createIcon($this, $title, $options);
        unset($options['label']);

        return parent::link($title, $url, $options);
    }
public function link ( $ title , $ url = null , array $ options = [ ] ) { $ options = $ this -> addClass ( $ options , $ this -> _class ( __FUNCTION__ ) ) ; $ options = Hash :: merge ( [ 'escapeTitle' => false , 'clear' => false , 'label' => $ title , ] , $ options ) ; $ isClear = ( bool ) $ options [ 'clear' ] ; unset ( $ options [ 'clear' ] ) ; $ options = $ this -> _setTitleAttr ( $ title , $ options ) ; //  Set title in html tag. if ( $ this -> _isEscapeTitle ( $ title , $ isClear , $ options ) ) { $ title = $ this -> tag ( 'span' , $ title , [ 'class' => $ this -> _class ( __FUNCTION__ ) . '-title' ] ) ; } $ options = $ this -> _getBtnClass ( $ options ) ; $ options = $ this -> _getToolTipAttr ( $ options ) ; list ( $ title , $ options ) = $ this -> _createIcon ( $ this , $ title , $ options ) ; unset ( $ options [ 'label' ] ) ; return parent :: link ( $ title , $ url , $ options ) ; }
Create an html link.

@param   string $title
@param   null|string|array $url
@param   array $options
@return  string
Create an html link .