PHP Class Catalin_SEO_Helper_Data

NOTICE OF LICENSE This source file is subject to the MIT License (MIT) that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: https://opensource.org/licenses/MIT
Inheritance: extends Mage_Core_Helper_Data
Mostra file Open project: caciobanu/improved-magento-layered-navigation Class Usage Examples

Public Methods

Method Description
appendSuffix ( string $url, string $suffix ) : string Appends the suffix to the url, if applicable.
getClearFiltersUrl ( ) : string Get the url to clear all layered navigation filters
getCurrentLayerParams ( array $params = null ) : array | null Getter for layered navigation params If $params are provided then it overrides the ones from registry
getFilterUrl ( array $filters, boolean $noFilters = false, array $q = [] ) : string Method to get url for layered navigation
getNofollow ( )
getPagerUrl ( array $query ) : string Get url for layered navigation pagination
getRoutingSuffix ( ) : string Retrieve routing suffix
getSearchFilter ( )
getShowMore ( )
getSkinJsUrl ( )
getUrlBody ( string $suffix, string $urlParts ) : string Get the url path, including the base url, minus the suffix.
isAjaxEnabled ( ) : boolean Check if ajax is enabled
isCatalogSearch ( ) : boolean Check if we are in the catalog search
isCategoryLinksEnabled ( ) : boolean Check if category links are enabled instead of the filter
isEnabled ( ) : boolean Check if module is enabled or not
isMultipleChoiceFiltersEnabled ( ) : boolean Check if multiple choice filters is enabled
isPriceSliderEnabled ( ) : boolean Check if price slider is enabled
seemsUtf8 ( string $string ) : boolean Check if a string has utf8 characters in it
transliterate ( string $text, string $separator = '-' ) : string Uses transliteration tables to convert any kind of utf8 character
utf8ToAscii ( string $str, string $unknown = '?' ) : string US-ASCII transliterations of Unicode text Warning: you should only pass this well formed UTF-8! Be aware it works by making a copy of the input string which it appends transliterated characters to - it uses a PHP output buffer to do this - it means, memory use will increase, requiring up to the same amount again as the input string
validUtf8 ( string $str ) : boolean Tests a string as to whether it's valid UTF-8 and supported by the Unicode standard

Protected Methods

Method Description
postProcessText ( string $text, string $separator ) : string Cleans up the text and adds separator

Method Details

appendSuffix() public method

Checks for Enterprise and if it is, adds the dot before returning
public appendSuffix ( string $url, string $suffix ) : string
$url string
$suffix string
return string

getClearFiltersUrl() public method

Get the url to clear all layered navigation filters
public getClearFiltersUrl ( ) : string
return string

getCurrentLayerParams() public method

Getter for layered navigation params If $params are provided then it overrides the ones from registry
public getCurrentLayerParams ( array $params = null ) : array | null
$params array
return array | null

getFilterUrl() public method

Method to get url for layered navigation
public getFilterUrl ( array $filters, boolean $noFilters = false, array $q = [] ) : string
$filters array array with new filter values
$noFilters boolean to add filters to the url or not
$q array array with values to add to query string
return string

getNofollow() public method

public getNofollow ( )

getPagerUrl() public method

Get url for layered navigation pagination
public getPagerUrl ( array $query ) : string
$query array
return string

getRoutingSuffix() public method

Retrieve routing suffix
public getRoutingSuffix ( ) : string
return string

getSearchFilter() public method

public getSearchFilter ( )

getShowMore() public method

public getShowMore ( )

getSkinJsUrl() public method

public getSkinJsUrl ( )

getUrlBody() public method

Checks for Enterprise and if it is, checks for the dot before returning
public getUrlBody ( string $suffix, string $urlParts ) : string
$suffix string
$urlParts string
return string

isAjaxEnabled() public method

Check if ajax is enabled
public isAjaxEnabled ( ) : boolean
return boolean

isCatalogSearch() public method

Check if we are in the catalog search
public isCatalogSearch ( ) : boolean
return boolean

isCategoryLinksEnabled() public method

Check if category links are enabled instead of the filter
public isCategoryLinksEnabled ( ) : boolean
return boolean

isEnabled() public method

Check if module is enabled or not
public isEnabled ( ) : boolean
return boolean

isMultipleChoiceFiltersEnabled() public method

Check if multiple choice filters is enabled

isPriceSliderEnabled() public method

Check if price slider is enabled
public isPriceSliderEnabled ( ) : boolean
return boolean

postProcessText() protected method

Cleans up the text and adds separator
protected postProcessText ( string $text, string $separator ) : string
$text string
$separator string
return string

seemsUtf8() public method

Check if a string has utf8 characters in it
public seemsUtf8 ( string $string ) : boolean
$string string
return boolean

transliterate() public method

Uses transliteration tables to convert any kind of utf8 character
public transliterate ( string $text, string $separator = '-' ) : string
$text string
$separator string
return string $text

utf8ToAscii() public method

US-ASCII transliterations of Unicode text Warning: you should only pass this well formed UTF-8! Be aware it works by making a copy of the input string which it appends transliterated characters to - it uses a PHP output buffer to do this - it means, memory use will increase, requiring up to the same amount again as the input string
public utf8ToAscii ( string $str, string $unknown = '?' ) : string
$str string UTF-8 string to convert
$unknown string Character use if character unknown
return string US-ASCII string

validUtf8() public method

Tests a string as to whether it's valid UTF-8 and supported by the Unicode standard
public validUtf8 ( string $str ) : boolean
$str string UTF-8 encoded string
return boolean true if valid