Skip to content

Instantly share code, notes, and snippets.

@sbruner
Last active January 18, 2016 01:57
Show Gist options
  • Save sbruner/94a8fe11becb66c5aa66 to your computer and use it in GitHub Desktop.
Save sbruner/94a8fe11becb66c5aa66 to your computer and use it in GitHub Desktop.
Piklist: field: editor: replace default
<?php
piklist('field', array(
'type' => 'editor',
'field' => 'post_content', // This is the field name of the WordPress default editor
'scope' => 'post', // Save to the wp_post table
'label' => 'Post Content',
'template' => 'field', // Only display the field not the label
'options' => array( // Pass any option that is accepted by wp_editor()
'wpautop' => true,
'media_buttons' => true,
'shortcode_buttons' => true,
'teeny' => false,
'dfw' => false,
'quicktags' => true,
'drag_drop_upload' => true,
'tinymce' => array(
'resize' => false,
'wp_autoresize_on' => true
)
)
));
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment