OXID eShop CE
6.1.5
|
Public Member Functions | |
__construct () | |
strlen ($sStr) | |
substr ($sStr, $iStart, $iLength=null) | |
strpos ($sHaystack, $sNeedle, $iOffset=null) | |
strstr ($sHaystack, $sNeedle) | |
strtolower ($sString) | |
strtoupper ($sString) | |
htmlspecialchars ($sString, $iQuotStyle=ENT_QUOTES) | |
htmlentities ($sString, $iQuotStyle=ENT_QUOTES) | |
html_entity_decode ($sString, $iQuotStyle=ENT_QUOTES) | |
preg_split ($sPattern, $sString, $iLimit=-1, $iFlag=0) | |
preg_replace ($aPattern, $sString, $sSubject, $iLimit=-1, $iCount=null) | |
preg_replace_callback ($pattern, $callback, $subject, $limit=-1, &$count=null) | |
preg_match ($sPattern, $sSubject, &$aMatches=null, $iFlags=null, $iOffset=null) | |
preg_match_all ($sPattern, $sSubject, &$aMatches=null, $iFlags=null, $iOffset=null) | |
ucfirst ($sSubject) | |
wordwrap ($sString, $iLength=75, $sBreak="\n", $blCut=null) | |
recodeEntities ($sInput, $blToHtmlEntities=false, $aUmls=[], $aUmlEntities=[]) | |
hasSpecialChars ($sStr) | |
cleanStr ($sStr, $sCleanChr=' ') | |
jsonEncode ($data) | |
strip_tags ($sString, $sAllowableTags='') | |
strrcmp ($sStr1, $sStr2) | |
Protected Attributes | |
$_sEncoding = 'UTF-8' | |
$_aUmls = ["\xc3\xa4", "\xc3\xb6", "\xc3\xbc", "\xC3\x84", "\xC3\x96", "\xC3\x9C", "\xC3\x9F"] | |
$_aUmlEntities = ['ä', 'ö', 'ü', 'Ä', 'Ö', 'Ü', 'ß'] | |
Class dealing with multibyte strings
OxidEsales\EshopCommunity\Core\StrMb::__construct | ( | ) |
Class constructor. The constructor is defined in order to be possible to call parent::__construct() in modules.
OxidEsales\EshopCommunity\Core\StrMb::cleanStr | ( | $sStr, | |
$sCleanChr = ' ' |
|||
) |
Replaces special characters with passed char. Special chars are:
\r \t \xc2\x95 \xc2\xa0 ;
string | $sStr | string to cleanup |
string | $sCleanChr | which character should be used as a replacement (default is empty space) |
OxidEsales\EshopCommunity\Core\StrMb::hasSpecialChars | ( | $sStr | ) |
Checks if string has special chars
string | $sStr | string to search in |
OxidEsales\EshopCommunity\Core\StrMb::html_entity_decode | ( | $sString, | |
$iQuotStyle = ENT_QUOTES |
|||
) |
PHP html_entity_decode() function wrapper
string | $sString | string being converted |
int | $iQuotStyle | quoting rule |
OxidEsales\EshopCommunity\Core\StrMb::htmlentities | ( | $sString, | |
$iQuotStyle = ENT_QUOTES |
|||
) |
PHP htmlentities() function wrapper
string | $sString | string being converted |
int | $iQuotStyle | quoting rule |
OxidEsales\EshopCommunity\Core\StrMb::htmlspecialchars | ( | $sString, | |
$iQuotStyle = ENT_QUOTES |
|||
) |
PHP htmlspecialchars() function wrapper
string | $sString | string being converted |
int | $iQuotStyle | quoting rule |
OxidEsales\EshopCommunity\Core\StrMb::jsonEncode | ( | $data | ) |
wrapper for json encode, which does not work with non utf8 characters
mixed | $data | data to encode |
OxidEsales\EshopCommunity\Core\StrMb::preg_match | ( | $sPattern, | |
$sSubject, | |||
& | $aMatches = null , |
||
$iFlags = null , |
|||
$iOffset = null |
|||
) |
PHP preg_match() function wrapper
string | $sPattern | pattern to search for, as a string |
string | $sSubject | input string |
array | $aMatches | is filled with the results of search |
int | $iFlags | flags |
int | $iOffset | place from which to start the search |
OxidEsales\EshopCommunity\Core\StrMb::preg_match_all | ( | $sPattern, | |
$sSubject, | |||
& | $aMatches = null , |
||
$iFlags = null , |
|||
$iOffset = null |
|||
) |
PHP preg_match_all() function wrapper
string | $sPattern | pattern to search for, as a string |
string | $sSubject | input string |
array | $aMatches | is filled with the results of search |
int | $iFlags | flags |
int | $iOffset | place from which to start the search |
OxidEsales\EshopCommunity\Core\StrMb::preg_replace | ( | $aPattern, | |
$sString, | |||
$sSubject, | |||
$iLimit = -1 , |
|||
$iCount = null |
|||
) |
PHP preg_replace() function wrapper
mixed | $aPattern | pattern to search for, as a string |
mixed | $sString | string to replace |
string | $sSubject | strings to search and replace |
int | $iLimit | maximum possible replacements |
int | $iCount | number of replacements done |
OxidEsales\EshopCommunity\Core\StrMb::preg_replace_callback | ( | $pattern, | |
$callback, | |||
$subject, | |||
$limit = -1 , |
|||
& | $count = null |
||
) |
PHP preg_replace() function wrapper
mixed | $pattern | pattern to search for, as a string |
callable | $callback | Callback function |
string | $subject | strings to search and replace |
int | $limit | maximum possible replacements |
int | $count | number of replacements done |
OxidEsales\EshopCommunity\Core\StrMb::preg_split | ( | $sPattern, | |
$sString, | |||
$iLimit = -1 , |
|||
$iFlag = 0 |
|||
) |
PHP preg_split() function wrapper
string | $sPattern | pattern to search for, as a string |
string | $sString | input string |
int | $iLimit | (optional) only sub strings up to limit are returned |
int | $iFlag | flags |
OxidEsales\EshopCommunity\Core\StrMb::recodeEntities | ( | $sInput, | |
$blToHtmlEntities = false , |
|||
$aUmls = [] , |
|||
$aUmlEntities = [] |
|||
) |
Recodes and returns passed input: if $blToHtmlEntities == true ä -> ä if $blToHtmlEntities == false ä -> ä
string | $sInput | text to recode |
bool | $blToHtmlEntities | recode direction |
array | $aUmls | language specific characters |
array | $aUmlEntities | language specific characters equivalents in entities form |
OxidEsales\EshopCommunity\Core\StrMb::strip_tags | ( | $sString, | |
$sAllowableTags = '' |
|||
) |
PHP strip_tags() function wrapper.
string | $sString | the input string |
string | $sAllowableTags | an optional parameter to specify tags which should not be stripped |
OxidEsales\EshopCommunity\Core\StrMb::strlen | ( | $sStr | ) |
PHP multi byte compliant strlen() function wrapper
string | $sStr | string to measure its length |
OxidEsales\EshopCommunity\Core\StrMb::strpos | ( | $sHaystack, | |
$sNeedle, | |||
$iOffset = null |
|||
) |
PHP multi byte compliant strpos() function wrapper
string | $sHaystack | value to search in |
string | $sNeedle | value to search for |
int | $iOffset | initial search position |
OxidEsales\EshopCommunity\Core\StrMb::strrcmp | ( | $sStr1, | |
$sStr2 | |||
) |
Compares two strings. Case sensitive. For use in sorting with reverse order
string | $sStr1 | String to compare |
string | $sStr2 | String to compare |
OxidEsales\EshopCommunity\Core\StrMb::strstr | ( | $sHaystack, | |
$sNeedle | |||
) |
PHP multi byte compliant strstr() function wrapper
string | $sHaystack | value to search in |
string | $sNeedle | value to search for |
OxidEsales\EshopCommunity\Core\StrMb::strtolower | ( | $sString | ) |
PHP multi byte compliant strtolower() function wrapper
string | $sString | string being lower cased |
OxidEsales\EshopCommunity\Core\StrMb::strtoupper | ( | $sString | ) |
PHP multi byte compliant strtoupper() function wrapper
string | $sString | string being lower cased |
OxidEsales\EshopCommunity\Core\StrMb::substr | ( | $sStr, | |
$iStart, | |||
$iLength = null |
|||
) |
PHP multi byte compliant substr() function wrapper
string | $sStr | value to truncate |
int | $iStart | start position |
int | $iLength | length |
OxidEsales\EshopCommunity\Core\StrMb::ucfirst | ( | $sSubject | ) |
OxidEsales\EshopCommunity\Core\StrMb::wordwrap | ( | $sString, | |
$iLength = 75 , |
|||
$sBreak = "\n" , |
|||
$blCut = null |
|||
) |
PHP wordwrap() function wrapper
string | $sString | input string |
int | $iLength | column width |
string | $sBreak | line is broken using the optional break parameter |
bool | $blCut | string is always wrapped at the specified width |
|
protected |
|
protected |
|
protected |