Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under LGPL. TinyMCE has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances.

0
votes
1answer
7 views

How to add table class for tables of TinyMCE advanced wordpress plugin?

If you want to add a class for tables created using tinyMCE advanced wordpress plugin. Please see my answer.
0
votes
1answer
18 views

Client on iPad accidentally adding <code> tag to posts while writing

A client of mine complains that text gets 'randomly highlighted' when he is writing Wordpress posts on his iPad Pro. He uses the web interface. I got him to stop deleting the 'highlighted' text and ...
0
votes
1answer
13 views

Add custom TinyMCE 4 Button: Is it mandatory to have one JS per button?

I'm editing a Wordpress Plugin, trying to add another button. I had a look to this question (Add custom TinyMCE 4 Button, Usable since WordPress 3.9-beta1). But it doesn't work The JS file: https://...
0
votes
1answer
29 views

Multiple Tinymce/wp_editor in WordPress >4.8

I'm struggling for two days and started here with success: Why Can't wp_editor Be Used in a Custom Widget? I managed to have multiple TMCE on one page (displayed by a widget); all save data ...
0
votes
0answers
25 views

Enable TinyMCE in theme which already has wp_editor

so recently i am using a theme with frontend posting plugin! The textarea is WYSIWYG but not show all Tinymce function. i checked the template .php file of the plugin and saw wp_editor line. Please ...
0
votes
0answers
11 views

WordPress wp_editor() inside hidden element rendering incorrectly

As part of a plugin I'm currently writing, I need to add multiple WordPress RTEs to the admin screens. Since the main screen has tabs that are handled with JavaScript, some of the editors are inside ...
0
votes
0answers
55 views

Solved: WordPress showing html <tags> instead of correct formatting text

Solved with disable '.$result->pitch_text.' and replace it with '.$result->pitch_text.'. Now presentation is correct. After installing TinyMCE for my textarea fields I see that the html tags are ...
0
votes
0answers
7 views

WordPress TinyMCE Editor not handling preformatted code text correctly in Custom Post Types

I've hit a brick wall that I cannot solve or find anything on the net. Using custom post types whenever I add preformatted code snippets the editor does not process it correctly, even when using text....
0
votes
0answers
30 views

Deny php execution in /wp-includes - using .htaccess in /wp-includes VS root folder

Trying to secure my WP site. In an attempt to deny php execution from the wp-includes folder wondering if these two methods are effectively doing the same thing? 1) add new .htaccess file to root of ...
0
votes
0answers
36 views

Gallery Previews Not Working - wp.editor JavaScript API

When using media buttons on the wp.editor JavaScript API, The default "Create Gallery" functionality is available. Selection and editing of the gallery is working perfectly fine, however the gallery ...
0
votes
1answer
21 views

Show image gallery from a custom field

I have a custom field in a custom post type. The custom field is a tinymce editor and I should echo out what user enters on it. If user enters text it is shown as well but when an image or a gallery ...
-1
votes
0answers
20 views

Tooltip Button not showing within WYSIWYG Toolbar

I've been using this code to insert a tooltip button within the WYSIWYG Toolbar in my Wordpress sites but for some reason it has stopped working. I'm wondering if an update to core may have been the ...
1
vote
0answers
15 views

How to edit content before post update

I'm creating a plugin that enables the user to highlight certain words (long words, long sentences etc.) in the TinyMCE Editor. You can see a live version here: https://tekstr.dk/app I'm converting ...
0
votes
0answers
11 views

Bugs after switching TinyMCE code editor to visual editor

I create a new site. I know the WordPress well. But I do not understand what the problem is. I ran into the following problem. When editing pages /posts in code mode – everything works well. After ...
0
votes
0answers
11 views

TinyMCE custom block format won't stay selected in dropdown menu - other buggy behavior

I'm adding a new format to the block formats dropdown (Heading 1, Heading 2, etc.) called "Heading 2 Light". I add this code in functions.php: function theme_tiny_mce_before_init( $init ) { $init[...
0
votes
1answer
88 views

Adding custom block formats to TinyMCE. Everything works until JavaScript error when applying the format

I'm trying to add an item into the block formats dropdown in TinyMCE. I would like to add a format called "Heading 2 Light". In functions.php I add this code: function theme_tiny_mce_before_init( $...
0
votes
2answers
36 views

Remove distraction free mode from teeny editor

I'm trying to remove the distraction free mode button from the editor, but i can't make it disapear. Here is the code im using: add_filter( 'wp_editor_settings', function($settings) { $...
0
votes
0answers
19 views

WordPress TinyMCE Editor plugin not copying values from input boxes into shortcode. Displaying VALUE=“undefined” for each

I am building a custom plugin on WordPress to insert a [video_embed] shortcode with two attributes ("id" and "border"). The button for the TinyMCE editor that I have created is working but does not ...
0
votes
0answers
18 views

“Formats” Select Menu in WP Editor doesn't show up with correct colour

I added the Dropdown "Formats" and defined some custom styles. The followed tutorial is in this section https://codex.wordpress.org/TinyMCE_Custom_Styles#Registering_Custom_Styles Everything is ...
3
votes
1answer
65 views

Tiny MCE editor stripping xlink:href parameter from SVG USE tag

I have an inline SVG tag with an embedded <USE> tag. HTML: <ul> <li><svg class="icon-user"><use xlink:href="#icon-user"></use></svg> My Account</li>...
1
vote
0answers
48 views

Popup box when Clicking on Insert into post button in wordpress

I need to show a alert popup on clicking Insert into Post button in Media Library of WordPress, if the selected Image is less than some width and height in Library. Where can I find the onClick event ...
0
votes
1answer
71 views

TinyMCE 4.7.11 - Enable hidden WordPress core plugins? (referencing a wp-includes from plugin.php)

I need a color picker for the visual editor (don't ask, not my idea). I thought the TinyMCE colorpicker plugin was removed in WordPress 3.9. However, I do see site/wp-includes/js/tinymce/plugins/...
2
votes
0answers
21 views

TinyMce in WordPress - Getting the “fullscreen” button to stay on the right when customising button layout

I'm using TinyMce inside WordPress and I have customised the button layout like so: add_filter( 'tiny_mce_before_init', 'blm_format_tiny_mce' ); add_filter( 'mce_buttons', '...
1
vote
0answers
26 views

trigger html cleanup for all posts

So i know that wordpress will auto clean / format html within posts / pages automatically when switching back and forth from text to visual: https://stackoverflow.com/questions/9907757/wordpress-...
1
vote
2answers
93 views

Customising the WordPress TinyMce editor and it's buttons

I'm trying to cutomise the TinyMce editor within WordPress and I took this code from an older WP site I did, but the buttons I have set don't seem to be working, for example, this is what I have: ...
1
vote
1answer
26 views

TinyMCE 4.7.11 custom styles using styleselect - what does the 'attributes' argument do?

I'm writing a plugin to add custom formats to TinyMCE using styleselect. I've scoured the documentation and hundreds of examples covering the inline, block, selector, classes, and wrapper arguments. ...
0
votes
0answers
60 views

wp_editor() not working in a widget

I have followed the steps and copied the codes exactly as it written by Ralf912 but it does not work on my WordPress installation. Why Can't wp_editor Be Used in a Custom Widget? I keep receiving ...
1
vote
1answer
32 views

How to reset 'Advance' tab on table property?

I want to use bootstrap table in my site without any mess up class, style. I just want to add bootstrap class. I can add these class in table properties general settings as follows: function ...
0
votes
1answer
38 views

Prevent markup being altered when switching between Visual and HTML editors

I've seen this question asked a few times, but none of the solutions have worked for me. Basically, when switching between TinyMCE and the HTML editor, my markup gets ruined. I have a nested list on ...
0
votes
0answers
25 views

How to add common TinyMCE wysiwyg buttons to the text widget

This is for the editor that appears in the Text Widget, not the normal TinyMCE editor that appears in post/page editing. I am designing a custom widget that is pretty much a copy paste of the text ...
0
votes
0answers
21 views

TinyMCE advanced plugin append (not replace) to 'Formats' menu from editor-style.css

I have successfully replaced the 'Formats' menu of TinyMCE advanced plugin by adding editor-styles.css. What I want is to append some styles in the 'Formats' (as neatly categorized in default), not ...
3
votes
1answer
226 views

Integrating inline tinymce editor in a component for a gutenberg block

I'm new to stack exchange. I hope my question is not to long. I want to integrate an inline tinymce editor in a component and use it in a gutenberg block. But my editors ui conflicts with gutenberg. (...
0
votes
0answers
96 views

Add CodeMirror in a custom TinyMCE button

I'm adding a custom button in the TinyMCE that opens a textarea where I can add code. Now since CodeMirror is included in the core, how do I make my textarea into a proper code editor? Currently I ...
0
votes
1answer
50 views

Text View (Code View) in WordPress Customizer TinyMCE Editor

I have implemented TinyMCE Editor in WordPress Customizer by putting this code in functions.php file: // TinyMCE Editor in Customizer if (class_exists('WP_Customize_Control')) { class ...
1
vote
1answer
74 views

Stop WordPress Visual Editor converting backticks into code blocks

I need my frontend wp_editor() to not convert backticks into code automatically. I have checked the settings config in the tiny_mce_before_init filter as well as the documentation on the TinyMCE ...
0
votes
0answers
61 views

TinyMCE function causes issue in AVADA theme

I use Avada Theme 5.5.2 + WP and discover an issue that is caused by the function my_tinymce_setup_function( $initArray ). When using this function it updates correct the into the tables. But in the ...
1
vote
0answers
77 views

How to Add TinyMCE to widget

I'm trying to create simple widget with TinyMCE rich editor but it's not working My widget code: add_action('widgets_init', 'string_example_name_init'); function string_example_name_init() { ...
2
votes
1answer
238 views

TinyMCE custom styles remove class when switching styles

I have added some custom styles to the TinyMCE editor using the tiny_mce_before_init filter hook. They work by adding classes to the block-level element. See the code below: function ...
0
votes
0answers
13 views

Autosave converts HTML entities, removes images from [caption]s

When I allow Wordpress to autosave, it removes certain HTML tags completely (img) while others get modified. Content before autosave: [caption id="attachment_2893068" align="alignnone" width="1200"]&...
1
vote
0answers
93 views

Custom Shortcode: define cursor position/insertion point?

I have created a shortcode and TinyMCE plugin for a shortcode. Click the button, it inserts [my-shortcode][/my-shortcode]. But it adds the code and then the editor cursor is after the closing ...
0
votes
1answer
105 views

WordPress Tinymce editor broken and nothing seems to fix it :(

First off, i've tried stuff posted here already, didnt help. Issue : Here is what i tried Tried renaming htaccess removing all plugins removing and reinstalling theme (there is only one ) tried ...
0
votes
0answers
67 views

TinyMCE adding non breakable space between links

I have a small issue, we are trying to have a hashtag block. Where each hashtag link leads to a different page. However, TinyMCE is adding &nbsp; between each link. Which leads to links not ...
0
votes
1answer
23 views

Changing code with (&nbsp;) when author updates their post (TinyMCE)

I have a problem like this: every save changes code <td></td> to <td>&nbsp;</td> which is terrible beacause I have big tables and it makes final code much bigger and ...
3
votes
0answers
40 views

How can I use the TinyMCE editor for the description field on a Media item?

When I view an image in my Media Library, the Description field textarea has a toolbar, but it's only for creating HTML tags. How can I get the TinyMCE wysywig editor to be used instead? I've found ...
1
vote
0answers
33 views

Asynchronously render shortcodes in TinyMCE visual editor

I created an img shortcode (e.g. [img attachment="19"]) that I want to render in real time in TinyMCE visual editor. So, I created a plugin for TinyMCE that replaces the shortcode in real time. Here ...
0
votes
0answers
12 views

How to prevent tinymce formats from multiselecting?

Is there a way or a setting to prevent this from happening. I tried hooking script like this on footer but it still wont bind to the buttons. add_action( 'wp_footer', function () { echo "<...
1
vote
0answers
39 views

TinyMCE custom plugin, how to make a word automatically selected based on current cursor position?

Making a custom plugin for TinyMCE, I wonder how to make a word automatically selected based on current cursor position, like in the the Wordpress "Add link" plugin. I've searched the WP TinyMCe ...
3
votes
2answers
299 views

Wait for Gutenberg or built something in ACF?

I have a client who has requested something, that's straight out of the box, if I was using ACF. However... Gutenberg should be here any minute now and revolutionize who the editor works. I've looked ...
1
vote
0answers
53 views

Visual editor not showing all table rows

Does anyone know why the visual editor does not show all table rows. I have over 30 rows of data, but in the visual editor only ten are visible, the text editor is the only way to access the rest. ...
2
votes
2answers
103 views

Using a dashicon for a custom button in TinyMCE?

I have created a custom button for TinyMCE and I would like it to use the Twitter icon from dashicons. I am hoping to be able to do this just through the Javascript with no additional CSS. Is this ...