admin管理员组文章数量:1130349
I have installed a theme with visual composer on my wordpress and everything was working fine until I added a widget above the header.
From that moment on, every time I want to create a new entry the RTE is always on text mode instead of visual.
I find it really weird that my customization have caused this, does anyone has another explanation and/or solution?
Thanks in advance!
I have installed a theme with visual composer on my wordpress and everything was working fine until I added a widget above the header.
From that moment on, every time I want to create a new entry the RTE is always on text mode instead of visual.
I find it really weird that my customization have caused this, does anyone has another explanation and/or solution?
Thanks in advance!
Share Improve this question asked Jul 10, 2015 at 7:38 viriatoviriato 1111 silver badge6 bronze badges1 Answer
Reset to default 0Can't really think of a reason for the behaviour, maybe it is just a bug in the theme, of course I can't say anything specific without knowing the code. But you should be able get around it by making use of the wp_default_editor hook and explicitly set the type of editor you want to show first, which is inside the function with the same name, so wp_default_editor().
function wpse194059_set_wp_default_editor( $editor ) {
// possible values are:
// tinymce - visual mode
// html - text mode
return 'tinymce';
}
add_filter( 'wp_default_editor', 'wpse194059_set_wp_default_editor' );
I have installed a theme with visual composer on my wordpress and everything was working fine until I added a widget above the header.
From that moment on, every time I want to create a new entry the RTE is always on text mode instead of visual.
I find it really weird that my customization have caused this, does anyone has another explanation and/or solution?
Thanks in advance!
I have installed a theme with visual composer on my wordpress and everything was working fine until I added a widget above the header.
From that moment on, every time I want to create a new entry the RTE is always on text mode instead of visual.
I find it really weird that my customization have caused this, does anyone has another explanation and/or solution?
Thanks in advance!
Share Improve this question asked Jul 10, 2015 at 7:38 viriatoviriato 1111 silver badge6 bronze badges1 Answer
Reset to default 0Can't really think of a reason for the behaviour, maybe it is just a bug in the theme, of course I can't say anything specific without knowing the code. But you should be able get around it by making use of the wp_default_editor hook and explicitly set the type of editor you want to show first, which is inside the function with the same name, so wp_default_editor().
function wpse194059_set_wp_default_editor( $editor ) {
// possible values are:
// tinymce - visual mode
// html - text mode
return 'tinymce';
}
add_filter( 'wp_default_editor', 'wpse194059_set_wp_default_editor' );
本文标签: visual editorRTE always on text mode by default
版权声明:本文标题:visual editor - RTE always on text mode by default 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:https://it.en369.cn/questions/1749115902a2318188.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。


发表评论