[wp-trac] [WordPress Trac] #23316: Top level admin sidebar menu items with conflicting positions bury one another

WordPress Trac noreply at wordpress.org
Fri Oct 30 21:00:29 UTC 2015


#23316: Top level admin sidebar menu items with conflicting positions bury one
another
------------------------------------+------------------------------
 Reporter:  beautomated             |       Owner:
     Type:  defect (bug)            |      Status:  new
 Priority:  normal                  |   Milestone:  Awaiting Review
Component:  Administration          |     Version:  3.5.1
 Severity:  major                   |  Resolution:
 Keywords:  dev-feedback has-patch  |     Focuses:
------------------------------------+------------------------------
Changes (by chriscct7):

 * keywords:  dev-feedback needs-refresh 2nd-opinion => dev-feedback has-
               patch


Comment:

 Patch: If the menu position is already in use, make the position it
 registers to a substring of the integer base conversion of the md5 of (the
 menu slug and menu title of the admin page being registered concatenated),
 multiplied by 0.00001 to always get a number < 1, and then added to the
 original menu position. This returns a nearly guaranteed unique number,
 that is repeatable to generate, and easy to do so

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


More information about the wp-trac mailing list