[wp-trac] [WordPress Trac] #17017: Check if a post has a featured image and get its URL (outside from the_loop)

WordPress Trac wp-trac at lists.automattic.com
Mon Apr 4 21:03:04 UTC 2011


#17017: Check if a post has a featured image and get its URL (outside from
the_loop)
-----------------------------+------------------------------
 Reporter:  wiltave          |       Owner:
     Type:  feature request  |      Status:  new
 Priority:  normal           |   Milestone:  Awaiting Review
Component:  General          |     Version:  3.1
 Severity:  normal           |  Resolution:
 Keywords:                   |
-----------------------------+------------------------------

Comment (by andrewryno):

 That may have been a poor choice of word on my part. That is the way it
 should be done by using those functions. It's just a little more than one
 function. wp_get_attachment_url()/wp_get_attachment_image_src() is used
 the way it should be, as well as the_post_thumbnail(). I don't see the
 point of having to add another function just to get the URL when there is
 already a function to do that. That's my opinion, though.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17017#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list