[wp-trac] [WordPress Trac] #43147: Introduce `esc_html_comment` and translation related functions

WordPress Trac noreply at wordpress.org
Wed Jan 24 08:58:57 UTC 2018


#43147: Introduce `esc_html_comment` and translation related functions
-------------------------------------------------+-------------------------
 Reporter:  jipmoors                             |       Owner:
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
Component:  Formatting                           |  Review
 Severity:  normal                               |     Version:  trunk
 Keywords:  has-patch has-unit-tests 2nd-        |  Resolution:
  opinion                                        |     Focuses:
-------------------------------------------------+-------------------------
Changes (by dd32):

 * keywords:  has-patch has-unit-tests => has-patch has-unit-tests 2nd-
               opinion


Comment:

 I don't personally think this is needed myself.

 The whole premise of the need for it is not being able to trust the data
 you're outputting, which if it's not hard coded, sounds like it should be
 being sanitised rather than escaped. WordPress also trusts translations
 inherently, meaning you should fix a translation that contains rogue HTML
 rather than simply attempting to escape the bad translations.

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


More information about the wp-trac mailing list