You are here

function _sheetnode_save in Sheetnode 5

Same name and namespace in other branches
  1. 6 sheetnode.module \_sheetnode_save()
  2. 7.2 sheetnode.module \_sheetnode_save()
  3. 7 sheetnode.module \_sheetnode_save()
2 calls to _sheetnode_save()
sheetnode_insert in ./sheetnode.module
Implementation of hook_insert().
sheetnode_update in ./sheetnode.module
Implementation of hook_update().

File

./sheetnode.module, line 703

Code

function _sheetnode_save($nid, $vid, $value) {
  db_query("DELETE FROM {sheetnode} WHERE vid=%d", $vid);
  db_query("INSERT INTO {sheetnode} (nid, vid, value) VALUES (%d, %d, '%s')", $nid, $vid, serialize(_sheetnode_sanitize_js($value)));
}