[wp-trac] [WordPress Trac] #52761: Date Permalinks

WordPress Trac noreply at wordpress.org
Wed Mar 10 13:43:33 UTC 2021


#52761: Date Permalinks
-------------------------+-----------------------------
 Reporter:  dshanske     |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Date/Time    |    Version:
 Severity:  normal       |   Keywords:
  Focuses:               |
-------------------------+-----------------------------
 This one surprised me that there is no functionality around it I could
 find in the code.

 A function to generate a date permalink. Specifically, in use case, let's
 say, in my post, I want to display the date.. March 10, 2021, and link it
 to the day archive. Then, on the day archive, I want a prev and next
 button for the day before and day after for better navigation.

 There is no simple functionality for this that I see. I can write
 functions to do this, but it seems to me there should be built in
 functions to figure out what date archive the current retrieved URL is, to
 generate the permalinks to a day, month, or year archive based on a
 WP_Post object/post ID or a DateTime object.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/52761>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list