[wp-trac] [WordPress Trac] #29807: add support for picture element and srcset attribute on img in wp_kses

WordPress Trac noreply at wordpress.org
Sun Feb 22 12:24:25 UTC 2015


#29807: add support for picture element and srcset attribute on img in wp_kses
-----------------------------------------+-----------------------------
 Reporter:  mattheu                      |       Owner:
     Type:  enhancement                  |      Status:  new
 Priority:  normal                       |   Milestone:  Future Release
Component:  Formatting                   |     Version:
 Severity:  normal                       |  Resolution:
 Keywords:  has-patch dev-feedback kses  |     Focuses:
-----------------------------------------+-----------------------------

Comment (by mattheu):

 I've refreshed this patch to merge cleanly.

 As there is now a feature plugin project for high res images, I think this
 would be needed.

 rmmcue I've looked into wp_kses_hair. You're right that its not so easy to
 try and validate the URLs in the srcset attribute. I'm not sure what to do
 here. The only thing I can think is that we could take srcset as a special
 case and then - knowing the format, we can get parse the string to grab
 the URLs and check for bad protocols. This is not easy to do though.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/29807#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list