Skip to main content
Share Your Experience: Take the 2024 Developer Survey

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
2 votes
1 answer
42 views

How to add placeholder in wp_editor?

i would like to add placeholder when using wp_editor() function. I tried to pass placeholder attribute in textarea, but didn't work. I tried to pass it in settings wp_editor( $...
Sak's user avatar
  • 23
0 votes
0 answers
30 views

Background color of edit post page

I noticed that the background color of the post editor page is different for different post types. Sometimes it is white, some times it is not. I'm attaching a screenshot of non-white example. Is this ...
upkagefa's user avatar
0 votes
1 answer
46 views

How to get wp_editor field content when it is inside a Form?

I am working with a plugin where admin needs to send Email to the user. For Email composing I have used wp_editor inside a FORM and the FOMR submission is handling with an AJAX call. How can I get the ...
Akramul's user avatar
0 votes
0 answers
13 views

Add custom text in /post.php?post=503&action=edit

I'd like to know how to add a custom text like "Hello world!" inside the edit post.
winona's user avatar
  • 131
0 votes
0 answers
65 views

wp_editor mce-view

We are using the wp_editor on a page on the front-end to allow subscribers to create a cpt post. We added support for auto-turning youtube urls into embed tags: function mce_scripts() { ...
shanebp's user avatar
  • 5,063
0 votes
0 answers
15 views

How to edit the Page?

I've opened the WordPress page for editing, but I'm having trouble locating the content I want to edit. Is it possibly hidden, or could there be another issue? Can anyone assist me in resolving this ...
max_den112233's user avatar
0 votes
0 answers
33 views

Add submenu page to a custom menu page

For a company project I'm fully customizing the wordpress wp-admin dashboard to be the front end after an user is logged in. I need to hide the admin bar for non admin users and add a submenù to a ...
ICTDEV's user avatar
  • 133
0 votes
0 answers
13 views

Wordpress Theme file editor - error with sleep() php function

I'm doing some tests by modifying my .php files directly from the wordpress theme editing interface ( /wp-admin/theme-editor.php ). (to avoid lengthy deployment pipelines) However, as soon as I add ...
Vincent Rocher's user avatar
0 votes
0 answers
24 views

How to make wordpress editor honor double <br> (shift+enter) but keep adding regular <p> made with enter key?

I'd like the editor to behave like this: - Press Enter > produces a paragraph (<p>) - Press Enter + Uppercase/Shift > produces a line break (<br>) - Press Enter + Uppercase/Shift ...
Luca Reghellin's user avatar
0 votes
0 answers
29 views

Multiple wp.editor in a custom widget using JQuery

Hi I'm trying to build a custom accordion widget with the possibility to add multiples panels with WYSIWYG editor. My issue is that the editor content from the javascript is not saved in my widget $...
Daniel Ringuet's user avatar
1 vote
0 answers
52 views

Why Is wp.editor Not Adding the ”Add Media” Button When I Initialize It?

I have a custom post type with a custom field that has an array of key-value pairs (Locations). I'm trying to load the wp.editor for one of the key-value pairs (Description) and it's working except it'...
Samuel Bacay's user avatar
2 votes
1 answer
205 views

How do I display and edit other posts within the 'Edit Post' area of Wp-Admin Dashboard

I'm wondering how to edit the 'New Post/Edit Post' area of Wordpress. I want to create a new 'Screen Element' like the plugins do. I want this area to display all posts with a corresponding taxonomy ...
DJZEEGLER's user avatar
  • 119
0 votes
1 answer
44 views

Theme Options wp_editor breaks with 6.0.2 update

I'm in the process of migrating my sites to a new server (windows -> nginx). One of my old themes has 4 options pages. One of the options pages includes 3 wp_editor instances. However, all 4 ...
user3593214's user avatar
0 votes
1 answer
258 views

WP Editor does not Initialize Correctly When Form Elements are Removed from the DOM

I am using js code to add and remove form elements and to initialize the wp_editor on the dynamically added textareas with js. The wp editor is initializing correctly when I am only adding elements ...
Badan's user avatar
  • 225
0 votes
1 answer
245 views

Add media button always inserts media on the next wp_editor instance when created dynamically

This is a really weird issue. I am trying to store data from a form in a plugin settings page and allow users to add html code with wp_editor. The users can dynamically add as many fields as they want ...
Badan's user avatar
  • 225
2 votes
1 answer
234 views

Loading a self-hosted custom @font-face into TinyMCE dropdowns (Classic Editor) via 'tiny_mce_before_init' filter

I can't work out how to load self-hosted custom fonts for preview in the font_formats and 'style_formats` dropdown in TinyMCE (Classic Editor). TinyMCE documentation shows this example for loading a ...
StudioAl's user avatar
  • 464
0 votes
0 answers
553 views

Creating an admin button that when clicked shows a popup form

I am creating a custom plugin to add a button to the buttons panel when editing a post or page in the classic editor. I have no trouble adding a button to the panel, but am unsure of the best way to ...
Johnathan's user avatar
2 votes
0 answers
230 views

Passing RichText attributes to function onChange

I have four RichText elements in a custom Gutenberg block I am developing, and they are all very similar except for the "name" attribute, which is currently hard-coded. What I need to do is ...
Garrett Massey's user avatar
0 votes
0 answers
519 views

Adding link options in insert/edit link dialog window

Good afternoon! I am looking for a way to insert a text box inside this insert/edit link dialog window. Due to googles recent changes for rel/nofollow links, we would like to insert an option to add a ...
sallycakes's user avatar
0 votes
0 answers
28 views

When the WP_EDITOR button is pressed, the user is prompted to select a photo from their device

wp_editor has an Add Media button but when the user clicks that button, it opens the media library. I want to make a button that when clicked it allows uploading a image from their device only.
Emirhan's user avatar
0 votes
1 answer
607 views

Get selected image URL from wp.media.editor.attachment into text input fails. What am I doing wrong?

I have placed a media button as a post meta field to insert an image URL into a text field when Insert Into Page button is clicked. It works up to the point of opening the media repository window, ...
Nadal's user avatar
  • 89
0 votes
3 answers
1k views

wp_editor visual tab in meta box doesn't show content

If you click on the Text tab, you can see the content, but when you switch back to the Visual tab, it displays nothing. It's not white text on white background either... it just has no content. The ...
Jeremy Caris's user avatar
1 vote
0 answers
147 views

Editor not displaying dynamically after clicking on the button

I am displaying the field dynamically in the admin panel. I have a button called Add more fields. The user can add the custom field dynamically. As of now, it's working but the issue is the editor not ...
Naren Verma's user avatar
1 vote
1 answer
2k views

How to make a custom field as an editor in wordpress?

I have to add the custom field in the WordPress admin panel and I tried and it's displaying. Below is the screenshot. I am using the below code. function wordpress_add_metaboxes() { add_meta_box( ...
Naren Verma's user avatar
1 vote
0 answers
91 views

wp_editor() youtube link does not load video

Hello I am trying to get a preview of the youtube video when pasted to the editor but it keeps loading plain instead of loading the video preview. I have created an options page in admin side for a ...
user avatar
1 vote
0 answers
176 views

How to use TinyMCE in the quick edit form?

I'm trying to make the description of a post editable - specifically the description of a WooCommerce product, but the issue should apply to any post type. I managed to implement it with a simple ...
kolli's user avatar
  • 111
0 votes
0 answers
33 views

Adding the image selector/uploader to an admin back page

I have created a couple of back end pages for a client using a very basic database, the client is wanting to add an image url to the database but using the built in image selector/uploader, I have ...
Chalkie's user avatar
0 votes
0 answers
36 views

dokan edit functionality

how can we have a functionality that every vendor inputs whatsapp number, and when customer need they can chat on whatsapp with any product vendor, enquire them also can place order on whatsapp, Will ...
ankur agarwal's user avatar
0 votes
1 answer
16 views

Unable to open specific posts on WP Dashboard [duplicate]

I have this weird problem in the last couple of days where it takes ~5 minutes to completely open some posts on WordPress wp-admin dashboard. Please hear me out carefully. 1 This is happening only ...
Yash Wate's user avatar
0 votes
0 answers
35 views

Bold button gets unchecked on enter click when bullet button is also selected in WP Editor

I am using wp_edior. Here is the scenario : Click bold, italic, bullets and write 1 line. Now press enter Bold and italic buttons gets unchecked. I tried below solution but it did not work for me. ...
Shweta Danej's user avatar
0 votes
2 answers
16 views

Include Recent Post in Category

I use a free WordPress Theme called DefautMag, It has a front page with 3 columns, In the front page settings, I could choose any category to display in any of these columns, But I want to display ...
Imhotep's user avatar
1 vote
2 answers
877 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 ...
Álvaro Franz's user avatar
1 vote
0 answers
204 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 ...
captainM's user avatar
0 votes
0 answers
140 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 ...
Reverend Bubbles's user avatar
1 vote
1 answer
438 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 ...
Tinstar's user avatar
  • 141
1 vote
0 answers
109 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 ...
Deepak Lakhara's user avatar
1 vote
0 answers
1k 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 ...
Akash's user avatar
  • 132
0 votes
0 answers
12 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 ...
kaizer's user avatar
  • 1
1 vote
1 answer
523 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 ...
sound wave's user avatar
1 vote
0 answers
362 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 ...
Amrit Ray's user avatar
1 vote
1 answer
729 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( $...
Kolawole Emmanuel Izzy's user avatar
1 vote
0 answers
506 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 ...
fraxool's user avatar
  • 121
18 votes
1 answer
2k 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( ...
spnzr's user avatar
  • 231
1 vote
0 answers
158 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 ...
jonnyK's user avatar
  • 91
3 votes
0 answers
231 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 ...
Engr IBM's user avatar
1 vote
1 answer
5k 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 <...
Laura's user avatar
  • 11
1 vote
1 answer
2k 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 ...
Lennart Bergmann's user avatar
0 votes
1 answer
649 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 ...
Darth Mikey D's user avatar
0 votes
2 answers
534 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: $...
sariDon's user avatar
  • 265
2 votes
1 answer
1k 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", '...
sariDon's user avatar
  • 265

1
2 3 4 5
7