I want to add a placeholder to the WordPress Editor content box.

When you create a new post, the title field shows "Enter Title Here" exactly same like editor. I have used a filter to add text in the editor, but the behaviour of the filter is not the same as the title field. When I click on title field, "Enter Title Here" is replaced with a blank space.


add_filter( 'default_content', 'my_editor_content' );

function my_editor_content( $content ) {
    $content .= '<b id="enter_desc_here" style="color: #BBBBBB;font-size: 1.7em;">Enter Description Here</b>';
    return $content;

Is it possible to use similar code to add a place holder to the Editor's Content box?

  • "i click on title field then "enter title here" is replace to blank space" what else do u expect from a placeholder ? – codepixlabs Aug 27 '13 at 9:53
  • But i want add for editor.. – Pritesh Mahajan Aug 27 '13 at 9:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.