function node_form_build_preview

7.x node.pages.inc node_form_build_preview($form, &$form_state)
6.x node.pages.inc node_form_build_preview($form, &$form_state)

Form submission handler for node_form().

Handles the 'Preview' button on the node form.

See also

node_form()

node_form_validate()

1 string reference to 'node_form_build_preview'
node_form in drupal-7.x/modules/node/node.pages.inc
Form constructor for the node add/edit form.

File

drupal-7.x/modules/node/node.pages.inc, line 356
Page callbacks for adding, editing, deleting, and revisions management for content.

Code

function node_form_build_preview($form, &$form_state) {
  $node = node_form_submit_build_node($form, $form_state);
  $form_state['node_preview'] = node_preview($node);
  $form_state['rebuild'] = TRUE;
}