function webform_protected_downloads_get_hash_details in Webform Protected Downloads 6
Same name and namespace in other branches
- 7 webform_protected_downloads.module \webform_protected_downloads_get_hash_details()
Retrieve details for this hash
Parameters
string $hash :
Return value
void
2 calls to webform_protected_downloads_get_hash_details()
- webform_protected_downloads_download_page in ./
webform_protected_downloads.page.inc - Displays the download page
- webform_protected_downloads_token_values in ./
webform_protected_downloads.module - Implementation of hook_token_values().
File
- ./
webform_protected_downloads.module, line 698 - This file contains hook declarations and functions for the Webform Protected Downloads module.
Code
function webform_protected_downloads_get_hash_details($hash) {
static $wpd_hash;
if (!isset($wpd_hash[$hash])) {
$result = db_query("SELECT * FROM {wpd_access_hashes} WHERE hash = '%s'", $hash);
$wpd_hash[$hash] = db_fetch_object($result);
}
return $wpd_hash[$hash];
}