Skip to content

Instantly share code, notes, and snippets.

@webflo
Created November 4, 2010 17:12
Show Gist options
  • Save webflo/662783 to your computer and use it in GitHub Desktop.
Save webflo/662783 to your computer and use it in GitHub Desktop.
Disable teaser include by default
<?php
function foo_form_alter(&$form, $form_state, $form_id) {
if ($form['#id'] == 'node-form' && in_array($form['#node']->type, array('story', 'page', 'bar'))) {
$form['body_field']['teaser_include']['#default_value'] = FALSE;
}
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment