Public Member Functions | |
stripGpcMagicQuotes () | |
strMan ($sVal, $sKey=null) | |
strRem ($sVal, $sKey=null) | |
getArrFldName ($sName) | |
assignValuesFromText ($sIn, $dVat=null) | |
assignValuesToText ($aIn) | |
formatCurrency ($dValue, $oActCur=null) | |
currency2Float ($sValue) | |
isSearchEngine ($sClient=null) | |
isValidEmail ($sEmail) | |
rebuildCache () | |
loadAdminProfile ($aInterfaceProfiles) | |
fRound ($sVal, $oCur=null) | |
toStaticCache ($sName, $sContent, $sKey=null) | |
fromStaticCache ($sName) | |
cleanStaticCache ($sCacheName=null) | |
toFileCache ($sKey, $sContents) | |
fromFileCache ($sKey) | |
oxResetFileCache () | |
getRemoteCachePath ($sRemote, $sLocal) | |
checkAccessRights () | |
seoIsActive ($blReset=false, $sShopId=null, $iActLang=null) | |
getShopBit ($iShopId) | |
bitwiseAnd ($iVal1, $iVal2) | |
bitwiseOr ($iVal1, $iVal2) | |
isValidAlpha ($sField) | |
redirect ($sUrl, $blAddRedirectParam=true) | |
showMessageAndExit ($sMsg) | |
oxMimeContentType ($sFileName) | |
logger ($sText, $blNewline=false) | |
strRot13 ($sStr) | |
prepareUrlForNoSession ($sUrl) | |
Static Public Member Functions | |
static | getInstance () |
Protected Member Functions | |
_oxFileCache ($blMode, $sName, $sInput=null) | |
_simpleRedirect ($sUrl, $sHeaderCode) | |
_addUrlParameters ($sUrl, $aParams) | |
_fillExplodeArray ($aName, $dVat=null) | |
_stripQuotes ($mInput) | |
Protected Attributes | |
$_iCurPrecision = null | |
$_sEmailTpl = "^([-!#\$%&'*+./0-9=?A-Z^_`a-z{|}~\177])+@([-!#\$%&'*+/0-9=?A-Z^_`a-z{|}~\177]+\\.)+[a-zA-Z]{2,6}\$" | |
$_aStaticCache | |
$_blSeoIsActive = null | |
Static Private Attributes | |
static | $_instance = null |
static oxUtils.getInstance | ( | ) | [static] |
oxUtils.stripGpcMagicQuotes | ( | ) |
Strips magic quotes
oxUtils.strMan | ( | $ | sVal, | |
$ | sKey = null | |||
) |
OXID specific string manipulation method
string | $sVal string | |
string | $sKey key |
oxUtils.strRem | ( | $ | sVal, | |
$ | sKey = null | |||
) |
OXID specific string manipulation method
string | $sVal string | |
string | $sKey key |
oxUtils.getArrFldName | ( | $ | sName | ) |
Returns string witch "." symbols were replaced with "__".
string | $sName String to search replaceble char |
oxUtils.assignValuesFromText | ( | $ | sIn, | |
$ | dVat = null | |||
) |
Takes a string and assign all values, returns array with values.
string | $sIn Initial string | |
double | $dVat Article VAT (optional) |
oxUtils.assignValuesToText | ( | $ | aIn | ) |
Takes an array and builds again a string. Returns string with values.
array | $aIn Initial array of strings |
oxUtils.formatCurrency | ( | $ | dValue, | |
$ | oActCur = null | |||
) |
Returns formatted currency string, according to formatting standards.
double | $dValue Plain price | |
object | $oActCur Object of active currency |
oxUtils.currency2Float | ( | $ | sValue | ) |
Returns formatted currency string, according to formatting standards.
string | $sValue Formatted price |
oxUtils.isSearchEngine | ( | $ | sClient = null |
) |
Checks if current web client is Search Engine. Returns true on success.
string | $sClient user browser agent |
oxUtils.isValidEmail | ( | $ | sEmail | ) |
oxUtils.rebuildCache | ( | ) |
Clears Smarty cache data.
oxUtils.loadAdminProfile | ( | $ | aInterfaceProfiles | ) |
Parses profile configuration, loads stored info in cookie
array | $aInterfaceProfiles ($myConfig->getConfigParam( 'aInterfaceProfiles' )) |
oxUtils.fRound | ( | $ | sVal, | |
$ | oCur = null | |||
) |
Rounds the value to currency cents
string | $sVal the value that should be rounded | |
object | $oCur Currenncy Object |
oxUtils.toStaticCache | ( | $ | sName, | |
$ | sContent, | |||
$ | sKey = null | |||
) |
Stores something into static cache to avoid double loading
string | $sName name of the content | |
mixed | $sContent the content | |
string | $sKey optional key, where to store the content |
oxUtils.fromStaticCache | ( | $ | sName | ) |
Retrieves something from static cache
string | $sName name under which the content is stored in the satic cache |
oxUtils.cleanStaticCache | ( | $ | sCacheName = null |
) |
Cleans all or specific data from static cache
string | $sCacheName Cache name |
oxUtils._oxFileCache | ( | $ | blMode, | |
$ | sName, | |||
$ | sInput = null | |||
) | [protected] |
Reads or write to filecache
boolean | $blMode true == write, false == read | |
string | $sName key under which the input should be stored | |
string | $sInput the content which should be stored in file cache |
oxUtils.toFileCache | ( | $ | sKey, | |
$ | sContents | |||
) |
Stores contents to file cache by given key.
string | $sKey Cache key | |
mixed | $sContents Contents to cache |
oxUtils.fromFileCache | ( | $ | sKey | ) |
Fetches contents from file cache.
string | $sKey Cache key |
oxUtils.oxResetFileCache | ( | ) |
Resets oxFileCache and deletes all cache files
oxUtils.getRemoteCachePath | ( | $ | sRemote, | |
$ | sLocal | |||
) |
If $sLocal file is older than 24h or doesn't exist, trys to download it from $sRemote and save it as $sLocal
string | $sRemote the file | |
string | $sLocal the adress of the remote source |
oxUtils.checkAccessRights | ( | ) |
oxUtils.seoIsActive | ( | $ | blReset = false , |
|
$ | sShopId = null , |
|||
$ | iActLang = null | |||
) |
Checks if Seo mode should be used
bool | $blReset used to reset cached SEO mode | |
string | $sShopId shop id (optional; if not passed active session shop id will be used) | |
int | $iActLang language id (optional; if not passed active session language will be used) |
oxUtils.getShopBit | ( | $ | iShopId | ) |
Returns integer number with bit set according to $iShopId. The acttion performed could be represented as pow(2, $iShopId - 1) We use mySQL to calculate that, as currently php int size is only 32 bit.
int | $iShopId current shop id |
oxUtils.bitwiseAnd | ( | $ | iVal1, | |
$ | iVal2 | |||
) |
Binary AND implementation. We use mySQL to calculate that, as currently php int size is only 32 bit.
int | $iVal1 value nr 1 | |
int | $iVal2 value nr 2 |
oxUtils.bitwiseOr | ( | $ | iVal1, | |
$ | iVal2 | |||
) |
Binary OR implementation. We use mySQL to calculate that, as currently php integer size is only 32 bit.
int | $iVal1 value nr 1 | |
int | $iVal2 value nr 2 |
oxUtils.isValidAlpha | ( | $ | sField | ) |
Checks if string is only alpha numeric symbols
string | $sField fieldname to test |
oxUtils._simpleRedirect | ( | $ | sUrl, | |
$ | sHeaderCode | |||
) | [protected] |
redirects browser to given url, nothing else done just header send may be used for redirection in case of an exception or similar things
string | $sUrl code to add to the header(e.g. "HTTP/1.1 301 Moved Permanently", or "HTTP/1.1 500 Internal Server Error" | |
string | $sHeaderCode the URL to redirect to |
oxUtils.redirect | ( | $ | sUrl, | |
$ | blAddRedirectParam = true | |||
) |
redirect user to the specified URL
string | $sUrl URL to be redirected |
oxUtils.showMessageAndExit | ( | $ | sMsg | ) |
shows given message and quits
string | $sMsg message to show |
oxUtils._addUrlParameters | ( | $ | sUrl, | |
$ | aParams | |||
) | [protected] |
adds the given paramters at the end of the given url
string | $sUrl a url | |
array | $aParams the params which will be added |
oxUtils._fillExplodeArray | ( | $ | aName, | |
$ | dVat = null | |||
) | [protected] |
Fill array.
array | $aName Initial array of strings | |
double | $dVat Article VAT |
oxUtils.oxMimeContentType | ( | $ | sFileName | ) |
returns manually set mime types
string | $sFileName the file |
oxUtils.logger | ( | $ | sText, | |
$ | blNewline = false | |||
) |
Processes logging.
string | $sText Log message text | |
bool | $blNewline If true, writes message to new line (default false) |
oxUtils._stripQuotes | ( | $ | mInput | ) | [protected] |
Recursively removes slashes from arrays
mixed | $mInput the input from which the slashes should be removed |
oxUtils.strRot13 | ( | $ | sStr | ) |
Applies ROT13 encoding to $sStr
string | $sStr to encoding string |
oxUtils.prepareUrlForNoSession | ( | $ | sUrl | ) |
prepareUrlForNoSession adds extra url params making it usable without session also removes sid=xxxx&
string | $sUrl public |
oxUtils.$_instance = null [static, private] |
oxUtils.$_iCurPrecision = null [protected] |
oxUtils.$_sEmailTpl = "^([-!#\$%&'*+./0-9=?A-Z^_`a-z{|}~\177])+@([-!#\$%&'*+/0-9=?A-Z^_`a-z{|}~\177]+\\.)+[a-zA-Z]{2,6}\$" [protected] |
oxUtils.$_aStaticCache [protected] |
oxUtils.$_blSeoIsActive = null [protected] |