[wp-trac] [WordPress Trac] #19695: Links widget does not generate width or height attributes when showing an image

WordPress Trac wp-trac at lists.automattic.com
Fri Dec 30 07:10:49 UTC 2011


#19695: Links widget does not generate width or height attributes when showing an
image
--------------------------+--------------------------------------
 Reporter:  mbijon        |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Widgets       |    Version:  3.3
 Severity:  normal        |   Keywords:  dev-feedback 2nd-opinion
--------------------------+--------------------------------------
 It's a best practice to include width and height attributes in image tags
 to prevent reflows when the browser renders the page. Both PageSpeed and
 YSlow include rules that measure this.

 {{{_walk_bookmarks()}}} in {{{/wp-includes/bookmark-template.php}}} does
 support adding images to the output of the Links widget. However, it
 doesn't output the width or height attributes.

 It is possible to size images with CSS instead of by tag attributes (and
 PageSpeed rules consider this acceptable). But it doesn't seem ideal to
 force users to set dimensions in CSS, when the Link edit page doesn't
 accept CSS directly. Plus, I think it's best to have all the meta info
 about something in one place, not to set an image in a WP link, and then
 the dimensions in a theme's CSS file.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/19695>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list