[wp-trac] [WordPress Trac] #23983: Add filter to get_post_thumbnail_id to override default thumbnail use

WordPress Trac noreply at wordpress.org
Thu Sep 6 20:40:50 UTC 2018


#23983: Add filter to get_post_thumbnail_id to override default thumbnail use
-------------------------------------------------+-------------------------
 Reporter:  Jesper800                            |       Owner:
                                                 |  SergeyBiryukov
     Type:  enhancement                          |      Status:  reviewing
 Priority:  normal                               |   Milestone:  5.0
Component:  Media                                |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  2nd-opinion needs-testing has-patch  |     Focuses:
-------------------------------------------------+-------------------------

Comment (by joemcgill):

 A filter makes sense to me, although I'm unsure if filtering the ID is the
 correct approach, since someone might also want to replace the thumbnail
 with an outside source that doesn't have an ID. However, adding a filter
 to `get_post_thumbnail_id()` before the post meta lookup seems like a fine
 enhancement.

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


More information about the wp-trac mailing list