get_option() is undefined in TinymceWindowManager
get_option() is undefined in TinymceWindowManager
get_option() is undefined in TinymceWindowManager
How to have html in TinyMce “Text” tab properly indented and highlighted
What you can do is use the get_current_screen() function to get what screen the current user is on ( in the admin panel ) and only add those global values whenever the user is viewing the post page: function my_format_TinyMCE( $in ) { $screen = get_current_screen(); if( is_object( $screen ) && ‘post’ == $screen->post_type ) … Read more
There are a number of problems: The tiny_mce_before_init filter does not affect the TinyMCE editor that VC instantiates for parameters with name == ‘content’ and type == ‘content_html’. VC gets the TinyMCE HTML markup in a separate AJAX request. The editor’s instantiation does not benefit from the tinyMCEPreInit inline JavaScript array that the filter affects. … Read more
Changed get_stylesheet_directory_uri() to get_stylesheet_directory(), and it works.
By default TinyMCE, the (visual) editor of WordPress, strips schema microdata from input. There are plugins (example) that will prevent this behaviour. Or you can do it yourself by adding this snippet to your functions.php (docs): function wpse238918_allow_schema ($in) { if(!empty($in[‘extended_valid_elements’])) $in[‘extended_valid_elements’] .= ‘,’; $in[‘extended_valid_elements’] .= ‘@[id|class|style|title|itemscope|itemtype|itemprop|datetime|rel],div,dl,ul,dt,dd,li,span,a|rev|charset|href|lang|tabindex|accesskey|type|name|href|target|title|class|onfocus|onblur]’; return $in; } add_filter(‘tiny_mce_before_init’, ‘wpse238918_allow_schema’ );
why don’t you use get_the_excerpt instead. That doesn’t have the paragraph marks. You can even use your own filters. something similar. <?php $my_excerpt = get_the_excerpt(); if ( ” != $my_excerpt ) { // Some string manipulation performed } echo $my_excerpt; // Outputs the processed value to the page ?> view more on the codex https://codex.wordpress.org/Function_Reference/get_the_excerpt … Read more
This question has been answered here You need to “add a simple filter function” to functions.php file for the theme via regex.
How do I externalize JQuery from my Tinymce Modal Dialog’s html and Enqueue the JS File to see JQuery
If you use the build-in tinyMCE editor you can do it this way: $content=””; $editor_id = ‘mycustomeditor’; wp_editor( $content, $editor_id ); Fill $content with your guidelines and they are shown if you open it. See https://codex.wordpress.org/Function_Reference/wp_editor