Questions tagged [wp-editor]

The wp_editor() function allows plugin and theme developers to render a custom instance of the TinyMCE editor used by WordPress

Filter by
Sorted by
Tagged with
1
vote
2answers
1k views

Visual/Text tabs in wp editor Not Showing

I have a wordpress website that i have added custom meta boxes to the post. Custom meta boxes have an editor using wp_editor(), but the editor is refusing to show the visual/text tabs on the editor ...
0
votes
2answers
788 views

Custom general settings (textarea field) don't output HTML correctly

I add my custom fields in genearal settings page. One of them using Wordpress Editor - there i insert my HTML content. I creeated it using simple snippet: add_action( 'admin_init', '...
0
votes
2answers
650 views

&nbsp when I use ENTER for skipping line

I don't know why when I'm using "Enter", that add &nbsp; in Pages/Posts Editor. That doesn't matter, but on my website, when I look the code &nbsp; makes this code : <p> � </p> ...
0
votes
1answer
1k views

WP_Editor Shortcode Issue

I have created a front-end editor using wp_editor that functions as it should. Upon testing I have noticed that it is stripping out any shortcodes that have been inserted in the content. I have ...
0
votes
1answer
1k views

Use ENTER, not SHIFT+ENTER to Insert Line Break in WP editor

I would like to use ENTER button to insert line break, not SHIFT + ENTER by default. I added this code into function.php. It works but the problem is the text-align buttons are not working. When I ...
1
vote
2answers
3k views

Disable WP Editor for specific page templates

The answer to this question is working great but I want to exclude the editor also when other templates are used. Can you please tell me how to extend the code to make this work with more than one ...
0
votes
1answer
472 views

wp.editor.initialize does not show the same default toolbar

In a custom post type of my plugin, for the edit post page, there is a WP Editor inside a metabox. In this metabox there is a button to add WP Editors via jQuery and Ajax. I managed to do it but wp....
4
votes
4answers
7k views

How to handle multiple instance of “send_to_editor” js function

Here is what I am doing: I Added wordpress media upload with iframe popup when a button or link clicked. And with click of insert into post the image url placed on a textbox. send_to_editor() ...
0
votes
1answer
31 views

Media library not working with wp_editor() on the front end

Very related: Add Media has stopped working in the front end since 4.5 update I want to run the wp_editor() function to load the classic WordPress editor on the Front-End. I need to do this out of ...
1
vote
0answers
27 views

Append wp_editor to Dynamically created textarea

So...the same question was asked 9 years ago: Dynamically textarea with TinyMce editor and I dont see a good answer and we now have the wp.editor API. Ive tried a few things, but cant add a WSYWIG ...
0
votes
1answer
1k views

How to stop wp-editor() overwriting my HTML?

I have the old problem that the WordPress editor overwrites my HTML code. For example, the editor inserts <p> and <br> tags where you don't have them set. The second problem is the editor ...
0
votes
2answers
1k views

Cannot Update A Post, 404 Error

After months of leaving and deleting my WordPress site, I decided to try again. I downloaded the new version 4.7.3, installed and added a new post. So far so good. I then went back to edit the post ...
0
votes
0answers
11 views

Theme options missing from edit page

I'm still somewhat new to WP, so I apologize if this is an obvious thing I'm missing. When I click to edit or create a page, I seem to remember that I would get a page with all sorts of options, and ...
1
vote
0answers
39 views

WP Editor Issue in Backend

I am stuck on silly issue of wp_editor function in WordPress backend in custom plugin page. See issue for wp_editor in attached images I have called the wp_editor function like this <?php ...
1
vote
2answers
946 views

wp_editor in widget breaks after save (no buttons and visual tab broken)

My goal is to get wp_editor working in a simple widget which the admin can use to add text content on an admin options page. Here we go in wp-admin/widgets.php everything looks sooo good right. When ...
0
votes
1answer
21 views

TinyMCE as comment editor - encoding issues

I've implemented TinyMCE as my comment form on both the front- and back-end, using the below code (sourced from some questions here): // Enable TinyMCE as frontend comment editor for new comments ...
0
votes
1answer
1k views

Inline Editing with wp_editor and tinymce (problem with textarea)

I want to use the new inline editing from tinymce with the wp_editor function in wordpress. Here is some info on how to set up tinymce inline editing http://www.tinymce.com/tryit/inline.php The code ...
0
votes
0answers
123 views

How to use wp_editor and save its data in wp_posts table

Recently I want to use wp_editor on a custom plugin where i add it inside a form and want to save its data in wp_posts table. So, I have created a new post type car and adds a field with wp_editor ...
1
vote
1answer
434 views

Can I use wp_editor() to create a second instance of the editor in my post page?

Looking at the codex and the code they provide, it doesn't seem like I can add a second editor. This looks like something more for front-end use rather than for use in the admin. If I am wrong, can ...
1
vote
1answer
469 views

WP_Editor - Setting render location on page

I'm trying to include wp_editor in a settings page. public function addEditor($content = '') { $editor_id = 'createposteditor'; $args = array( 'textarea_rows' => 15, ...
0
votes
1answer
531 views

Is it possible to disable the image alignment options in the post editor?

By default, when you insert an image into a post, it has some image alignment options (see below). In my theme I want every image to be full width. Of course, it's easy for me to change the front-end ...
1
vote
1answer
579 views

How to dynamically generate wordpress editor on frontend?

I want to initialize the wordpress editor dynamically on frontend. I have tried to include the following scripts: wp_enqueue_script('editor'); wp_enqueue_script('media-upload'); wp_enqueue_script('...
7
votes
2answers
7k views

Show Default Editor on Blog Page ( Administration Panel )

In WordPress 4.2 it included a nice feature which labeled what page was the Front-Page and which page was the Blog ( Latest Posts ). Unfortunately, it also removes the default editor on the page ...
0
votes
0answers
10 views

My edits are not saved

Everything used to be fine, but now for some reason I’m editing the record, but the old content remains, the new one for some reason does not appear. For example, I have everything stored in the pages ...
1
vote
1answer
53 views

Style classic editor buttons

I'm trying to style the buttons in the classic editor of wordpress, in particular to change color of the text inside or change the font-wright property. Using the browser inspector tool I looked for ...
1
vote
0answers
24 views

wpautop is not working when displaying content saved using wp_editor in a custom meta box

I am using wp_editor in a custom meta box. It is saving the content to the post metadata. And displaying it in the meta box as it should. The problem is when I am trying to display this content on ...
1
vote
1answer
55 views

Limit Block format tags in WordPress wp_editor

I'm working on a custom meta box and i am trying to limit the Block format tag to just P, H3 and H4 tags, i did it this way and not sure why it doesn't display the block format dropdown; wp_editor( $...
1
vote
0answers
33 views

Removing line breaks when in text view with wp_editor

While working on a custom plugin, I needed to add the wp_editor in the admin to let the user add its own content. I want the user to be able to write custom rich texts with the "Visual" editor mode ...
7
votes
0answers
339 views

How to filter or remove default panels in Gutenberg PrePublish Panel

I would like to edit the text or remove and re-create the Publish panel of Gutenberg's PrePublish Panel in the editor sidebar. I know I can use wp.data.dispatch( 'core/edit-post' ).removeEditorPanel( ...
1
vote
0answers
30 views

How to set wp_editor to be email friendly?

I am sending emails via wp_mail() using a text/html header. So i need html formatted content. I want to use wp_editor() to edit my custom email template options. It has a Visual and Text tab for ...
0
votes
2answers
4k views

Add Media Upload Capabilities Needed for Custom Role for non-Posts

I finally managed to update an old WP 3.3.1 site to WP 4.1 with few issues, but one unexpected change seems to have come about with relation to file uploads. In the WP 3.3.1 version of the plugin, I ...
0
votes
0answers
70 views

/home1/vultusbl/public_html/wp-includes/class-wp-hook.php on line 286

Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'et_tabs_admin' not found or invalid function name in /home1/vultusbl/public_html/wp-includes/class-wp-hook.php on ...
0
votes
0answers
61 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. Everything is correct, but there's a small issue: My custom formats titles within the ...
2
votes
0answers
60 views

How can I control multiple editing of wordpress posts?

I am managing multiple authors blog, I have issues of editors taking over the stories that someone else is currently editing. The default wordpress warning will display but some of them ignore it and ...
1
vote
1answer
595 views

Convert this textarea to rich html format via wp_editor

I have a texarea in a page that works like a charm, but I would like to convert the area to a html rich wp_editor. Could anyone tell me how to convert this textarea to a wp_editor field?? Thanks <...
0
votes
0answers
22 views

Blank page for editing page, console error

When I try to edit or create a new post, I receive a blank page but I still can view the full source of the page and seems that all displayed without PHP errors. On console there is error for react-...
0
votes
0answers
110 views

Why there is no edit handle on my elementor page?

I have a page built with elementor. There are multiple blocks on my page but I don't see the edit handle when I hover over an element/section. As seen in the attached screenshot, the mouse is hovering ...
0
votes
1answer
182 views

How can I get the standard WP-Editor through Javascript?

In PHP I can do wp_editor( 'content', 'editor_id', array() ); And the result looks like this: The standard WP-Editor with all the buttons, plus my custom button (the blue square). I have tried to ...
0
votes
1answer
86 views

Make wp_editor required

I have a page with multiple wp_editors. I need to make 2 of them required. I tried the following, but it didn't work. I did put it right after the function that loads the page, but not sure if it ...
2
votes
1answer
141 views

Add table controls with wp_editor minimal editor configuration ('teeny')

I want to add the table controls for wp_editor(tinymce) initiated with teeny=>true. Here is what I have done so far (without success): <?php $tinymce_options = array('plugins' => "table", '...
0
votes
2answers
73 views

wp_editor in add_meta_boxes does not show gallery

I have added a meta box in the page edit section: add_meta_box('custom_section_box', 'Sections', array($this, 'section_box'), 'page','normal','high'); Within the box, there is a wp_editor call: $...
0
votes
1answer
49 views

How do I render content from a wp_editor in a plugin setting field?

I have a plugin setting that uses wp_editor() to handle the input and will get echoed as part of a shortcode. Everything is working great on the admin side but when I echo the output on the client ...
1
vote
1answer
327 views

Front end wp_editor not rendering audio/video links

I have an editor on the front end of a website using wp_editor. It mostly works as expected; very similar to the admin side editor. However, when I enter an audio or video link, the players are not ...
0
votes
2answers
135 views

How can I apply preventDefault() to the click on CodeMirror-hints?

If I click on a selection in the autocompleter of WordPress in codeMirror, the whole field is closed. To prevent this I want to add preventDefault to the click event. var cm = wp.codeEditor....
0
votes
1answer
170 views

Load WordPress Editor .css on Front End

This issues seems to have cropped up for me after a recent WordPress udpate (I'm on 4.9.9) as I haven't had issues before. I load wp_editor on the front end using the following code: $argswp = ...
0
votes
1answer
668 views

Gutenberg - Custom blocks not working as expected?

I am making my very first custom block in gutenburg editor using this tutorial. NOTE:- ALL THE CODE I HAVE WRITTEN IS INSIDE THE THEME NOT AS A PLUGIN And the output came correctly the block started ...
0
votes
1answer
435 views

wp.editor.initialize does nothing

I'm trying to add additional wp_editor instances when a user clicks an "Add content" button in the back-end. I have it mostly working, except that the user needs to save the post after adding the ...
0
votes
3answers
265 views

Is there a way to get wp_editor (tinymce) content?

I want to get the wp_editor (tinymce) content then find a sentence by specific word with regex. However, have no idea how to get the content When a post is published or updated, the function will get ...
1
vote
1answer
41 views

WordPress code editor VS customizer “built-in CSS editor”?

I needed to make some CSS changes to my WordPress site (child theme) earlier and opened the WordPress editor inside "Appearance": Appearance > Editor > someCssFile.css Inside the editor page, ...
0
votes
1answer
24 views

See double taxonomy inputs in WP editor

I registered 3 taxonomies for a custom post type, but they show up in 2 places when editing a custom post type. I would like to only display the input boxes on the right of the editor. How to remove ...

1 2 3 4 5 6