[wp-trac] [WordPress Trac] #62763: get_calendar(): IDs may be duplicated

WordPress Trac noreply at wordpress.org
Mon Jan 6 12:08:23 UTC 2025


#62763: get_calendar(): IDs may be duplicated
--------------------------+------------------------------
 Reporter:  wildworks     |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  General       |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:
--------------------------+------------------------------

Comment (by vineet2003):

 Hi @hbhalodia,

 Thanks for your input! I understand the desire to keep things simple and
 avoid adding extra filters. However, I believe adding filters to customize
 the calendar IDs (as I suggested) would provide more flexibility in the
 long run. Some developers might rely on the default wp-calendar and today
 IDs for their JavaScript or CSS, and changing them without a way to
 customize could break their existing functionality.

 Using wp_unique_id() directly is a great solution for preventing
 duplicates, but I think offering the option to customize the IDs via
 filters would give developers the control they need while avoiding
 potential conflicts.

 Let me know your thoughts on striking a balance between simplicity and
 flexibility!

 Thanks

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


More information about the wp-trac mailing list