Created
June 9, 2018 08:21
-
-
Save danmaby/0cda0df9b8b474939ccb3ecf77d33112 to your computer and use it in GitHub Desktop.
default editor label for my_custom_post_type
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// default editor label for my_custom_post_type | |
add_action('admin_footer', 'add_title_to_editor'); | |
function add_title_to_editor() { | |
global $post; | |
if (get_post_type($post) == 'my_custom_post_type') : ?> | |
<script> jQuery('<h3>Optional Additional Information</h3>').insertBefore('#postdivrich'); </script> | |
<? endif; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment