X

Add “Next-page” button in WYSIWYG-editor

Adding this PHP code to the functions.php of your wordpress theme will add a nextpage button to the WYSIWYG editor.



Code Snippet:


add_filter('mce_buttons','wysiwyg_editor');
function wysiwyg_editor($mce_buttons) {
$pos = array_search('wp_more',$mce_buttons,true);
if ($pos !== false) {
$tmp_buttons = array_slice($mce_buttons, 0, $pos+1);
$tmp_buttons[] = 'wp_page';
$mce_buttons = array_merge($tmp_buttons, array_slice($mce_buttons, $pos+1));
}
return $mce_buttons;
}

Comments  Leave a Reply

  1. jkhjhjkh

  2. lkjlkjlkjl

  3. ah, thats how its working

  4. Have used this a few times in the past and came to this site when I was trying to find the code for it again.. thanks for posting this great resource!

  5. Great success, works as advertised!

    1.  Cool glad to hear it 🙂

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.

WordPress Launch Checklist

The Ultimate WordPress Launch Checklist

We've compiled all the essential checklist items for your next WordPress website launch into one handy ebook.
Yes, Send Me the Free eBook!