function upload_space_used in Drupal 4
Same name and namespace in other branches
- 5 modules/upload/upload.module \upload_space_used()
- 6 modules/upload/upload.module \upload_space_used()
Determine how much disk space is occupied by a user's uploaded files.
Parameters
$uid: The integer user id of a user.
Return value
The amount of disk space used by the user in bytes.
1 call to upload_space_used()
- _upload_validate in modules/
upload.module
File
- modules/
upload.module, line 502 - File-handling and attaching files to nodes.
Code
function upload_space_used($uid) {
return db_result(db_query('SELECT SUM(filesize) FROM {files} f INNER JOIN {node} n ON f.nid = n.nid WHERE n.uid = %d', $uid));
}