Home Forums Backend Issues (wp-admin) WYSIWYG always defaults to text mode


WYSIWYG always defaults to text mode

  • Users editing custom post types with ACF WYSIWYG’s on the screen are always defaulting to the “Text” tab. Changing to another tab does not seem to save as the default. This is a recent problem that seems to only be limited to users within a new user role we created that has the following capabilities:

    Copy posts, create posts, delete others posts, delete posts, delete private posts, delete published posts, edit others posts, edit posts, edit private posts, edit published posts, manage categories, moderate comments, publish posts, read, read private posts, unfiltered upload, upload files

    Admins and editors are not having a problem. Any advice on how to fix or troubleshoot this? Thanks!

  • Anyone have any ideas?

  • I did some testing on and I cannot recreate it.

    What editor is shown is determined by the last action a user takes in a wysiwyg field, any field. WP, not ACF stores a value on the last selection, visual or text and the next time the editor is loaded all of the wysiwyg fields will be set to this tab.

    I do not know how or where this value is stored by WP, but you can see it in action on an user where it is working correctly. Open any post, change the mode of any wysiwyg editor, wait a second or 2 and reload the page, all editors should not be in the last mode selected.

    Further testing shows that this selection is stored somewhere and is not related to a cookie value. Clearing cookies for the site doe not effect it. Again, looking for how this is stored I can find nothing. I did find this however, I do not see the meta value in the DB changing.

    The only thing that I can think of is the there is a filter on the WP hook user_can_richedit that is returning false for this user type.

  • Maybe this might help:

    add_filter( 'wp_default_editor', 'my_default_editor' );
    function my_default_editor() {
        return "html"; // TEXT mode
        // return "tinymce"; // VISUAL mode

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.