Make WordPress Core

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#47617 closed defect (bug) (invalid)

Using wp_editor in {$taxonomy}_edit_form_fields not working

Reported by: flyonthenetcom's profile Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: TinyMCE Keywords:
Focuses: Cc:


Consider this simple piece of code:

function test_form_fields( ) {
	echo '<tr class="form-field term-description-wrap"><th scope="row">Snippet</th><td>';
	wp_editor( 'TEST', 'snippet', array(
		'textarea_name' => 'snippet'
	echo '</td></tr>';
add_action( 'category_add_form_fields', 'test_form_fields');
add_action( 'category_edit_form_fields', 'test_form_fields');

It's expected to show a functional TinyMCE editor, but something weird is rendered, seems mixed up with description field.

  • Content not displayed (empty tinyMCE)
  • No toolbar rendered
  • No textarea tag with id "snippet" in source code
  • Media / Visual / Text are applied to description field

Attachments (1)

wp_editor.PNG (24.8 KB) - added by 5 years ago.

Download all attachments as: .zip

Change History (4)

#1 follow-up:
5 years ago

  • Resolution set to invalid
  • Status changed from new to closed

#2 in reply to: ↑ 1
5 years ago

Replying to

term-description-wrap class is causing the problem

#3 @SergeyBiryukov
5 years ago

  • Component changed from General to TinyMCE
  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.