WordPress.org

Make WordPress Core

Opened 6 months ago

Closed 6 days ago

#53062 closed defect (bug) (invalid)

iFrame in Taxonomies

Reported by: Loewenherz Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 5.7.1
Component: Taxonomy Keywords:
Focuses: Cc:

Description

After the update to 5.7.1, iFrames in taxonomies (tags) are deleted on save. Code in functions.php like remove_filter( 'term_description', 'wp_kses_data' ); doesn't work not longer.

Change History (2)

#1 @SergeyBiryukov
6 months ago

  • Component changed from General to Taxonomy
  • Summary changed from iFrame in Taxonomien to iFrame in Taxonomies
  • Version set to 5.7.1

#2 @zodiac1978
6 days ago

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

There is no bug here. You need to remove both filter:

remove_filter( 'term_description', 'wp_kses_data' );
remove_filter( 'pre_term_description', 'wp_filter_kses' );

Or with Yoast activated (then the post context is used):

remove_filter( 'term_description', 'wp_kses_post' );
remove_filter( 'pre_term_description', 'wp_filter_post_kses' );

Although it would be even better to use the wp_kses_allowed_html filter to just add iframe to the list of allowed HTML tags with the used attributes for YouTube (if that is your use case for example).

Note: See TracTickets for help on using tickets.