function sheetnode_load in Sheetnode 6
Same name and namespace in other branches
- 7.2 sheetnode.module \sheetnode_load()
- 7 sheetnode.module \sheetnode_load()
Implementation of hook_load().
File
- ./
sheetnode.module, line 51
Code
function sheetnode_load($node) {
$data = new StdClass();
$data->sheetnode = db_fetch_array(db_query("SELECT * FROM {sheetnode} WHERE nid=%d AND vid=%d", $node->nid, $node->vid));
if (!is_array($data->sheetnode)) {
$data->sheetnode = array(
'value' => '',
'nid' => $node->nid,
'vid' => $node->vid,
);
}
return $data;
}