public function paginationSortPjax($key = null, $title = null, $options = []) {
		if (empty($options)) {
			$options = [];
		} elseif (!is_array($options)) {
			$options = [$options];
		}

		$optionsDefault = $this->_getOptionsForElem('paginationSortPjax.linkOpt');
		if ($this->request->is('modal')) {
			$optionsDefault['data-toggle'] = 'modal';
			//$optionsDefault['data-disable-use-stack'] = 'true';
		}

		$sortKey = $this->Paginator->sortKey();
		if (!empty($sortKey) && ($key === $sortKey)) {
			$sortDir = $this->Paginator->sortDir();
			if ($sortDir === 'asc') {
				$dirIcon = $this->_getOptionsForElem('paginationSortPjax.iconDir.asc');
			} else {
				$dirIcon = $this->_getOptionsForElem('paginationSortPjax.iconDir.desc');
			}
			$title .= $dirIcon;
			$options['escape'] = false;
		}

		return $this->Paginator->sort($key, $title, $options + $optionsDefault);
	}
public function paginationSortPjax($key = null, $title = null, $options = []) {
		if (empty($options)) {
			$options = [];
		} elseif (!is_array($options)) {
			$options = [$options];
		}

		$optionsDefault = $this->_getOptionsForElem('paginationSortPjax.linkOpt');
		if ($this->request->is('modal')) {
			$optionsDefault['data-toggle'] = 'modal';
			//$optionsDefault['data-disable-use-stack'] = 'true';
		}

		$sortKey = $this->Paginator->sortKey();
		if (!empty($sortKey) && ($key === $sortKey)) {
			$sortDir = $this->Paginator->sortDir();
			if ($sortDir === 'asc') {
				$dirIcon = $this->_getOptionsForElem('paginationSortPjax.iconDir.asc');
			} else {
				$dirIcon = $this->_getOptionsForElem('paginationSortPjax.iconDir.desc');
			}
			$title .= $dirIcon;
			$options['escape'] = false;
		}

		return $this->Paginator->sort($key, $title, $options + $optionsDefault);
	}
public function paginationSortPjax ( $ key = null , $ title = null , $ options = [ ] ) { if ( empty ( $ options ) ) { $ options = [ ] ; } elseif ( ! is_array ( $ options ) ) { $ options = [ $ options ] ; } $ optionsDefault = $ this -> _getOptionsForElem ( 'paginationSortPjax.linkOpt' ) ; if ( $ this -> request -> is ( 'modal' ) ) { $ optionsDefault [ 'data-toggle' ] = 'modal' ; //$optionsDefault['data-disable-use-stack'] = 'true'; } $ sortKey = $ this -> Paginator -> sortKey ( ) ; if ( ! empty ( $ sortKey ) && ( $ key === $ sortKey ) ) { $ sortDir = $ this -> Paginator -> sortDir ( ) ; if ( $ sortDir === 'asc' ) { $ dirIcon = $ this -> _getOptionsForElem ( 'paginationSortPjax.iconDir.asc' ) ; } else { $ dirIcon = $ this -> _getOptionsForElem ( 'paginationSortPjax.iconDir.desc' ) ; } $ title .= $ dirIcon ; $ options [ 'escape' ] = false ; } return $ this -> Paginator -> sort ( $ key , $ title , $ options + $ optionsDefault ) ; }
Generates a sorting link used PJAX request. Sets named parameters for the sort and direction.
Handles direction switching automatically.

### Options:

- `escape` Whether you want the contents html entity encoded, defaults to true.
- `model` The model to use, defaults to PaginatorHelper::defaultModel().
- `direction` The default direction to use when this link isn't active.
- `lock` Lock direction. Will only use the default direction then, defaults to false.

@param string $key The name of the key that the recordset should be sorted.
@param string $title Title for the link. If $title is null $key will be used
for the title and will be generated by inflection.
@param array|string $options Options for sorting link. See above for list of keys.
@return string A link sorting default by 'asc'. If the resultset is sorted 'asc' by the specified
key the returned link will sort by 'desc'.
@link http://book.cakephp.org/2.0/en/core-libraries/helpers/paginator.html#PaginatorHelper::sort,
https://github.com/defunkt/jquery-pjax
Generates a sorting link used PJAX request . Sets named parameters for the sort and direction . Handles direction switching automatically .