You are here

function _revisioning_unpublish_node in Revisioning 6.4

Same name and namespace in other branches
  1. 8 revisioning_api.inc \_revisioning_unpublish_node()
  2. 6.3 revisioning_api.inc \_revisioning_unpublish_node()
  3. 7 revisioning_api.inc \_revisioning_unpublish_node()

Unpublish node, without calling node_save().

Parameters

$node: Target $node object or nid of target node

1 call to _revisioning_unpublish_node()
_revisioning_unpublish_revision in ./revisioning_api.inc
Unpublish revision (i.e. the node).

File

./revisioning_api.inc, line 211
API functions of Revisioning module

Code

function _revisioning_unpublish_node($node) {
  $nid = is_object($node) ? $node->nid : $node;
  db_query("UPDATE {node} SET status=0 WHERE nid=%d", $nid);
  cache_clear_all();
}