contenido\classes\class.purge.php
Description:
Contenido Purge class to reset some datas and files.
- Author
- Munkh-Ulzii Balidar
- Copyright
- four for business AG
- License
- http://www.contenido.org/license/LIZENZ.txt
- Link
- http://www.4fb.de
- Link
- http://www.contenido.org
- Package
- Contenido Backend classes
- Since
- file available since contenido release <= 4.8.12 $Id:
- Version
- 1.0.0
\Purge
Package: Default













class Purge
Properties
Methods

__construct(object $db, array $cfg, array $cfgClient) : voidConstructor of class
Parameters
| Name | Type | Description |
|---|---|---|
| $db | object | |
| $cfg | array | |
| $cfgClient | array |

clearClientCache( $iClientId, $sCacheDir = 'cache/') : booleanClear the cache directory for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | ||
| $sCacheDir |
| Type | Description |
|---|---|
| boolean |

clearClientHistory( $iClientId, $bKeep, $iFileNumber, $sVersionDir = 'version/') : booleanClear the cache directory for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | ||
| $bKeep | ||
| $iFileNumber | ||
| $sVersionDir |
| Type | Description |
|---|---|
| boolean |

clearClientLog(int $iClientId, string $sLogDir = 'logs/') : booleanClear client log file
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | int | |
| $sLogDir | string |
| Type | Description |
|---|---|
| boolean |

clearConCache( $sCacheDir = 'cache/') : booleanClear the cache directory for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $sCacheDir |
| Type | Description |
|---|---|
| boolean |

clearConCronjob( $sCronjobDir = 'cronjobs/') : booleanClear contenido log files
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $sCronjobDir |
| Type | Description |
|---|---|
| boolean |

clearConLog(string $sLogDir = 'logs/') : booleanClear contenido log files
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $sLogDir | string |
| Type | Description |
|---|---|
| boolean |

clearDir(string $sDirPath, string $sTmpDirPath, boolean $bKeep = false, array $aTmpFileList = array()) : booleanDelete all files and sub directories in a directory
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $sDirPath | string | |
| $sTmpDirPath | string |
|
| $bKeep | boolean | |
| $aTmpFileList | array |
|
| Type | Description |
|---|---|
| boolean |

emptyFile( $sDirPath, $aTypes) : booleanEmpty a file content
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $sDirPath | ||
| $aTypes |
| Type | Description |
|---|---|
| boolean |

getClientDir(int $iClientId) : stringGet frontend directory name for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | int |
| Type | Description |
|---|---|
| string | $sClientDir |

resetClientConCatArt(int $iClientId) : booleanReset the table con_cat_art for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | int |
| Type | Description |
|---|---|
| boolean |

resetClientConCode(int $iClientId) : booleanReset the table con_code for a client
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $iClientId | int |
| Type | Description |
|---|---|
| boolean |

resetPHPLibActiveSession() : booleanReset the table con_phplib_active_sessions
Returns
| Type | Description |
|---|---|
| boolean |

setCronjobFileTypes(array $aTypes) : voidSet cronjob file types
Parameters
| Name | Type | Description |
|---|---|---|
| $aTypes | array |