[wp-trac] [WordPress Trac] #58102: Check PHPcs Coding standard into the wp-includes folder

WordPress Trac noreply at wordpress.org
Fri Apr 7 10:31:07 UTC 2023


#58102: Check PHPcs Coding standard into the wp-includes folder
--------------------------+-------------------------------
 Reporter:  viralsampat   |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  General       |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:  coding-standards
--------------------------+-------------------------------

Comment (by audrasjb):

 Also adding `esc_attr()` to `$type_attr` in
 `<style<?php echo $type_attr; ?> media="print">#wpadminbar { display:none;
 }</style>`
 looks wrong to me, as `$type_attr` may contain an attribute + its value
 (example: `type="text/css"`.

 If we want to escape this variable, I think `esc_html` would be more
 appropriate here.

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


More information about the wp-trac mailing list