From 583701741a1c8f9608875761bd70bd517fdd0626 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 31 Aug 2006 14:59:28 +0000 Subject: - Patch #80470 by Eaton et al: better handling of programmatic submission. --- modules/node/node.module | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'modules/node/node.module') diff --git a/modules/node/node.module b/modules/node/node.module index 149580839..1c92d03b9 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -5,25 +5,6 @@ * @file * The core that allows content to be submitted to the site. Modules and scripts may * programmatically submit nodes using the usual form API pattern. - - * CREATE/EDIT NODE EXAMPLE - * $type = 'story'; - * $node = array('type' => $type); - * $form = drupal_retrieve_form($type. '_node_form', $node); - * $form['#post']['edit']['nid'] = 112; // send this if performing an edit - * $form['#post']['edit']['name'] = 'amy'; - * $form['#post']['edit']['title'] = 'robotitle'; - * $form['#post']['edit']['body'] = 'hello world'; - * $goto = drupal_process_form($type. '_node_form', $form); - * - * DELETE SINGLE NODE EXAMPLE - * $node = node_load(112); - * $form = drupal_retrieve_form('node_delete_confirm', $node); - * $form['#post']['op'] = t('Delete'); - * $goto = drupal_process_form('node_delete_confirm', $form); - * - * Calling form_get_errors() will list any validation errors that prevented the - * form from being submitted. */ define('NODE_NEW_LIMIT', time() - 30 * 24 * 60 * 60); -- cgit v1.2.3