diff options
Diffstat (limited to 'includes/file.inc')
-rw-r--r-- | includes/file.inc | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/includes/file.inc b/includes/file.inc index 1b06895af..baa0a9473 100644 --- a/includes/file.inc +++ b/includes/file.inc @@ -536,8 +536,8 @@ function file_save(stdClass $file) { * - If file already exists in $destination either the call will error out, * replace the file or rename the file based on the $replace parameter. * - Adds the new file to the files database. If the source file is a - * temporary file, the resulting file will also be a temporary file. - * @see file_save_upload() for details on temporary files. + * temporary file, the resulting file will also be a temporary file. See + * file_save_upload() for details on temporary files. * * @param $source * A file object. @@ -553,6 +553,7 @@ function file_save(stdClass $file) { * - FILE_EXISTS_RENAME - Append _{incrementing number} until the filename is * unique. * - FILE_EXISTS_ERROR - Do nothing and return FALSE. + * * @return * File object if the copy is successful, or FALSE in the event of an error. * @@ -1070,7 +1071,7 @@ function file_unmanaged_delete_recursive($path) { function file_space_used($uid = NULL, $status = FILE_STATUS_PERMANENT) { $query = db_select('file', 'f'); // Use separate placeholders for the status to avoid a bug in some versions - // of PHP. @see http://drupal.org/node/352956 + // of PHP. See http://drupal.org/node/352956. $query->where('f.status & :status1 = :status2', array(':status1' => $status, ':status2' => $status)); $query->addExpression('SUM(f.filesize)', 'filesize'); if (!is_null($uid)) { @@ -1127,7 +1128,7 @@ function file_save_upload($source, $validators = array(), $destination = FALSE, // Check for file upload errors and return FALSE if a lower level system // error occurred. For a complete list of errors: - // @see http://php.net/manual/en/features.file-upload.errors.php + // See http://php.net/manual/en/features.file-upload.errors.php. switch ($_FILES['files']['error'][$source]) { case UPLOAD_ERR_INI_SIZE: case UPLOAD_ERR_FORM_SIZE: @@ -1734,8 +1735,8 @@ function file_upload_max_size() { * @return * The internet media type registered for the extension or * application/octet-stream for unknown extensions. - * @see - * file_default_mimetype_mapping() + * + * @see file_default_mimetype_mapping() */ function file_get_mimetype($uri, $mapping = NULL) { if ($wrapper = file_stream_wrapper_get_instance_by_uri($uri)) { @@ -1818,6 +1819,7 @@ function drupal_chmod($uri, $mode = NULL) { * @param $uri * A string containing the URI to verify. If this value is omitted, * Drupal's public files directory will be used [public://]. + * * @return * The absolute pathname, or FALSE on failure. * @@ -1853,6 +1855,7 @@ function drupal_realpath($uri) { * * @param $uri * A URI or path. + * * @return * A string containing the directory name. * @@ -1894,6 +1897,7 @@ function drupal_dirname($uri) { * Default to FALSE. * @param $context * Refer to http://php.net/manual/en/ref.stream.php + * * @return * Boolean TRUE on success, or FALSE on failure. * @@ -1929,6 +1933,7 @@ function drupal_mkdir($uri, $mode = NULL, $recursive = FALSE, $context = NULL) { * @param $prefix * The prefix of the generated temporary filename. * Note: Windows uses only the first three characters of prefix. + * * @return * The new temporary filename, or FALSE on failure. * |