diff options
author | Dries Buytaert <dries@buytaert.net> | 2006-08-31 14:59:28 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2006-08-31 14:59:28 +0000 |
commit | 583701741a1c8f9608875761bd70bd517fdd0626 (patch) | |
tree | cc571746da2a6749a4aaae0f5db880a8d2384904 /modules/node/node.module | |
parent | 02e23b4f62975edbf7332984484c9b8a0e3a0850 (diff) | |
download | brdo-583701741a1c8f9608875761bd70bd517fdd0626.tar.gz brdo-583701741a1c8f9608875761bd70bd517fdd0626.tar.bz2 |
- Patch #80470 by Eaton et al: better handling of programmatic submission.
Diffstat (limited to 'modules/node/node.module')
-rw-r--r-- | modules/node/node.module | 19 |
1 files changed, 0 insertions, 19 deletions
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); |