[wp-trac] [WordPress Trac] #61719: WP_HTML_Tag_Processor doesn't allow to set a valid image src
WordPress Trac
noreply at wordpress.org
Fri Aug 2 22:58:03 UTC 2024
#61719: WP_HTML_Tag_Processor doesn't allow to set a valid image src
--------------------------+------------------------------
Reporter: ivanzhuck | Owner: dmsnell
Type: defect (bug) | Status: closed
Priority: normal | Milestone: Awaiting Review
Component: HTML API | Version: 6.6
Severity: normal | Resolution: fixed
Keywords: has-patch | Focuses:
--------------------------+------------------------------
Changes (by dmsnell):
* owner: (none) => dmsnell
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"58844" 58844]:
{{{
#!CommitTicketReference repository="" revision="58844"
HTML API: Indicate when WordPress rejects attribute updates.
When setting an an attribute value in the HTML API, WordPress may reject
an update based on rules in `kses`. In these cases, the return value from
an escaping function will be an empty string, and the HTML API should
reject the update. Unfortunately, it currently reports that it updates the
attribute but sets an empty string value, which is misleading.
In this patch, the HTML API will refuse the attribute update and return
false to indicate as much when WordPress rejects the updates.
Developed in https://github.com/wordpress/wordpress-develop/pull/7114
Discussed in https://core.trac.wordpress.org/ticket/61719
Follow-up to [58472].
Props: amitraj2203, dmsnell, mukesh27.
Fixes #61719.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/61719#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list