Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #57169, comment 6


Ignore:
Timestamp:
01/04/2023 02:40:21 PM (21 months ago)
Author:
Chouby
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #57169, comment 6

    initial v1  
    55For the language switcher, there is a unique menu item in database (and a unique menu item displayed in the backend). However, this menu item is splitted on frontend to get one menu item per language. Of course, we had to set a unique ID for the dynamic menu items and so we append the language code to the db menu item id resulting in non numeric menu item IDs. If you are interested in the Polylang code: See https://github.com/polylang/polylang/blob/3.3/frontend/frontend-nav-menu.php#L134
    66
    7 Would it be possible to avoid the cast to int the test?
     7Would it be possible to avoid the cast to int in the test?
    88