Contenido_UrlBuilder_MR

Extends abstract Contenido_UriBuilder class and implements singleton pattern.

Usage:

cInclude('classes', 'uri/class.uriBuilder.MR.php');
$url = 'front_content.php?idart=123';
$mrUriBuilder = cUriBuilderMR::getInstance();
$mrUriBuilder->buildUrl(array($url));
$newUrl = $mrUriBuilder->getUrl();
deprecated [2012-09-06] Use cUriBuilderMR instead of this class.
author Murat Purc
package CONTENIDO Plugins

 Methods

Builds a URL based on defined mod rewrite settings.

buildUrl(array $params, boolean $bUseAbsolutePath) : string
Inherited

Index keys of $aParams will be used as "a", corresponding values as "1" in this sample.

inherited_from \cUriBuilderMR::buildUrl()

Parameters

$params

array

Parameter array, provides only following parameters: $params[0] = 'front_content.php?idart=123...'

$bUseAbsolutePath

boolean

Flag to use absolute path (not used at the moment)

Exceptions

\cInvalidArgumentException

Returns

stringNew build url

Return http base path, e.g.

getHttpBasePath() : string
Inherited

http://contenido.org/

inherited_from \cUriBuilder::getHttpBasePath()
inherited_from \cUriBuilderMR::getHttpBasePath()

Returns

string

Returns a instance of cUriBuilderMR

getInstance() : \cUriBuilderMR
Static

It is meant to be an abstract function but not declared as abstract, because PHP Strict Standards are against abstract static functions.

deprecated 2012-09-06 this function is not supported any longer use function located in cUriBuilderMR instead of this function

Exceptions

\cBadMethodCallException If child class has not implemented this function

Returns

Return built URL

getUrl() : string
Inherited
inherited_from \cUriBuilder::getUrl()
inherited_from \cUriBuilderMR::getUrl()

Returns

string

Set http base path, e.g.

setHttpBasePath($sBasePath) : void
Inherited

http://contenido.org/

inherited_from \cUriBuilder::setHttpBasePath()
inherited_from \cUriBuilderMR::setHttpBasePath()

Parameters

$sBasePath

Constructor, tries to set some member variables.

__construct() 
deprecated 2012-09-06 this function is not supported any longer use function located in cUriBuilderMR instead of this function

Builds the SEO-URL by analyzing passed arguments (parameter value pairs)

_buildUrl(array $aParams) : string
Inherited
inherited_from \cUriBuilderMR::_buildUrl()

Parameters

$aParams

array

Parameter array

Returns

stringNew build pretty url

Loops thru passed parameter array and creates the query part of the URL.

_createUrlQueryPart(array $aArgs) : string
Inherited

All non CONTENIDO related parameter will be excluded from composition.

inherited_from \cUriBuilderMR::_createUrlQueryPart()

Parameters

$aArgs

array

Assoziative parameter array

Returns

stringComposed query part for the URL like '?foo=bar&param=value'

Returns articlename depending on current setting

_getArticleName(array $aPretty, array $aArgs) : string
Inherited
inherited_from \cUriBuilderMR::_getArticleName()

Parameters

$aPretty

array

Pretty url array

$aArgs

array

Additional arguments

Returns

stringArticlename

Returns client id or name depending on settings.

_getClientParameter(array $aArgs) : mixed
Inherited
inherited_from \cUriBuilderMR::_getClientParameter()

Parameters

$aArgs

array

Additional arguments

Returns

mixedClient id, client name or null

Returns language id or name depending on settings.

_getLanguageParameter(array $aArgs) : mixed
Inherited
inherited_from \cUriBuilderMR::_getLanguageParameter()

Parameters

$aArgs

array

Additional arguments

Returns

mixedLanguage id, language name or null

Returns composed path of url (normally the category structure)

_getPath(array $aPretty) : string
Inherited
inherited_from \cUriBuilderMR::_getPath()

Parameters

$aPretty

array

Pretty url array

Returns

stringPath

 Properties

 

$sHttpBasePath : string
Inherited

http://contenido.org/

inherited_from \cUriBuilder::$$sHttpBasePath
inherited_from \cUriBuilderMR::$$sHttpBasePath
 

$sUrl : string
Inherited
inherited_from \cUriBuilder::$$sUrl
inherited_from \cUriBuilderMR::$$sUrl
 

$_aMrCfg : array
Inherited
inherited_from \cUriBuilderMR::$$_aMrCfg
 

$_bIsXHTML : bool
Inherited
inherited_from \cUriBuilderMR::$$_bIsXHTML
 

$_bMREnabled : bool
Inherited
inherited_from \cUriBuilderMR::$$_bMREnabled
 

$_instance : \cUriBuilderMR
Inherited
inherited_from \cUriBuilderMR::$$_instance
 

$_sAmp : string
Inherited
inherited_from \cUriBuilderMR::$$_sAmp