function _loadMD5 in Bibliography Module 7.2
Same name and namespace in other branches
- 6 biblio.contributors.inc \_loadMD5()
- 7 includes/biblio.contributors.inc \_loadMD5()
Return value
unknown_type
File
- includes/
biblio.contributors.inc, line 455
Code
function _loadMD5() {
static $md5 = array();
static $count = 0;
$db_count = db_query("SELECT COUNT(*) FROM {biblio_contributor_data}")
->fetchField();
if ($db_count != $count) {
//refresh the cached data as some new authors may have been added or removed
$count = $db_count;
$md5 = array();
$result = db_query('SELECT md5,cid FROM {biblio_contributor_data} ');
foreach ($result as $row) {
$md5[$row->cid] = $row->md5;
}
}
return count($md5) ? $md5 : NULL;
}