function flash_load in Flash Node 5
Implementation of hook_load
File
- ./
flash.module, line 406
Code
function flash_load(&$node) {
// get the flash file associated with this node, it has filename _flash
$result = db_query("SELECT filepath FROM {files} WHERE nid=%d AND filename='%s'", $node->nid, '_flash');
$node->flash['_flash'] = db_result($result);
// retrieve parameters associated with this file from flash table
$result = db_query("SELECT height, width, version, build, display FROM {flash} WHERE nid=%d", $node->nid);
// store all the settings in to the $node->flash object
$settings = db_fetch_object($result);
foreach ($settings as $parameter => $value) {
$node->flash[$parameter] = $value;
}
}