[wp-trac] [WordPress Trac] #39909: Make title behaviours consistent across all widgets on first load

WordPress Trac noreply at wordpress.org
Sun Mar 5 07:16:11 UTC 2017


#39909: Make title behaviours consistent across all widgets on first load
-------------------------+--------------------
 Reporter:  karmatosed   |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  4.7.4
Component:  Widgets      |     Version:
 Severity:  normal       |  Resolution:
 Keywords:  needs-patch  |     Focuses:
-------------------------+--------------------
Changes (by westonruter):

 * keywords:  has-patch => needs-patch


Comment:

 @bor0 a couple points about [attachment:39909.3.patch]:

 * The `esc_attr_e()` function, like the other translation functions,
 should not be passed a variable but rather a string. If you want to pass a
 variable, like `$this->name`, you should use `echo esc_attr( $this->name
 )`.
 * I'm not sure that it is right to print `$this->name`. I believe it
 should copy the string literal from the widget's `widget` method as @dlh
 showed in [attachment:39909.2.patch].
 * The change to `class-wp-widget-tag-cloud.php` is using a printing
 function in string concatenation, so that won't have the desired result.

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


More information about the wp-trac mailing list