node_load

Trying to make this code do the equivalent of clicking "edit" and "save" on the indicated node. Help?

  1. <?php
  2.  
  3. // Bootstrap Drupal
  4. require 'includes/bootstrap.inc';
  5. drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
  6.  
  7.  
  8. // Attempt the DB query
  9. $node = node_load(12);
  10. node_save($node);
  11.  
  12. ?>
Syndicate content