[wp-trac] [WordPress Trac] #51908: add_image_size not working with custom plugin code

WordPress Trac noreply at wordpress.org
Tue Dec 1 18:01:43 UTC 2020


#51908: add_image_size not working with custom plugin code
-------------------------------+------------------------------
 Reporter:  arpitgshah         |       Owner:  (none)
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  Media              |     Version:
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:  docs
-------------------------------+------------------------------
Changes (by SergeyBiryukov):

 * focuses:   => docs
 * component:  General => Media


Comment:

 Hi there, welcome to WordPress Trac! Thanks for the report.

 Some context from
 [https://wordpress.slack.com/archives/C02RQBWTW/p1606844703391900 #core on
 Slack]:
 > `add_image_size()` should be called on the `after_setup_theme` action
 hook. It's not clear from the inline documentation, but there's a
 [https://developer.wordpress.org/reference/functions/add_image_size/#comment-296
 comment on the developer hub detailing that].

 Let's use this ticket to clarify the inline documentation :)

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


More information about the wp-trac mailing list