| [ Index ] |
|
Code source de GeekLog 1.4.1 |
[Code source] [Imprimer] [Statistiques]
(pas de description)
| Poids: | 531 lignes (17 kb) |
| Inclus ou requis: | 0 fois |
| Référencé: | 0 fois |
| Nécessite: | 0 fichiers |
downloader:: (21 méthodes):
downloader()
_addWarning()
_addError()
_addDebugMsg()
_logItem()
_setAvailableExtensions()
limitByIP()
setLogFile()
setLogging()
loggingEnabled()
setDebug()
printErrors()
printWarnings()
printDebugMsgs()
areErrors()
setAllowedExtensions()
getAllowedExtensions()
checkExtension()
setPath()
getPath()
downloadFile()
Classe: downloader - X-Ref
This class allows you to download a file from outside the web tree. Many hooks| downloader() X-Ref |
| Constructor |
| _addWarning($warningText) X-Ref |
| Adds a warning that was encountered param: string $warningTextText of warning |
| _addError($errorText) X-Ref |
| Adds an error that was encountered param: string $errorText Text of error |
| _addDebugMsg($debugText) X-Ref |
| Adds a debug message param: string $debugText Text of debug message |
| _logItem($logtype, $text) X-Ref |
| Logs an item to the log file param: string $logtype can be 'warning' or 'error' param: string $text Text to log to log file return: boolean true on success otherwise false |
| _setAvailableExtensions($extensions = array() X-Ref |
| Defines superset of available Mime types. param: array $extensions string array of valid mime types this object will accept |
| limitByIP($validIPS = array('127.0.0.1') X-Ref |
| Extra security option that forces all attempts to upload a file to be done so from a set of VERY specific IP's. This is only good for those who are paranoid param: $array $validIPS Array of valid IP addresses to allow file uploads from return: boolean returns true on success otherwise false |
| setLogFile($logFile = '') X-Ref |
| Sets log file param: string $fileName fully qualified path to log files return: boolean true on success otherwise false |
| setLogging($switch) X-Ref |
| Enables/disables logging of errors and warnings param: boolean $switch flag, true or false |
| loggingEnabled() X-Ref |
| Returns whether or not logging is enabled return: boolean true if logging is enabled otherwise false |
| setDebug($switch) X-Ref |
| Will force the debug messages in this class to be printed param: boolean $switch flag, true or false |
| printErrors($verbose=true) X-Ref |
| This function will print any errors out. This is useful in debugging param: boolean $verbose will print errors to web browser if true return: boolean string of all errors |
| printWarnings() X-Ref |
| This function will print any warnings out. This is useful in debugging |
| printDebugMsgs() X-Ref |
| This function will print any debmug messages out. |
| areErrors() X-Ref |
| Returns if any errors have been encountered thus far return: boolean True if errors occurred otherwise false |
| setAllowedExtensions($validExtensions = array() X-Ref |
| Sets allowed mime types for this instance param: array $allowedMimeTypes Array of allowed mime types |
| getAllowedExtensions() X-Ref |
| Gets allowed mime types for this instance return: array array of allowed mime types/file extensions |
| checkExtension($extension) X-Ref |
| Checks to see that mime type for current file is allowed for upload param: string $extension Verifies file extension is allowed for download return: boolean true if allowed otherwise false |
| setPath($uploadDir) X-Ref |
| Sets file upload path param: string $uploadDir Directory on server to store uploaded files return: boolean true on success otherwise false |
| getPath() X-Ref |
| Returns directory to upload to return: string returns directory where files for downloading reside |
| downloadFile($fileName) X-Ref |
| Attempts to dowload a file param: $string $fileName file to download without path return: boolean true on success otherwise false |
| Généré le : Wed Nov 21 12:27:40 2007 | par Balluche grâce à PHPXref 0.7 |
|