Timeline for How to switch between two primary menus (programatically0
Current License: CC BY-SA 4.0
3 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Aug 15, 2019 at 6:38 | comment | added | Manyang | if $menu is empty, that mean you dont have any menu location. But you say you have primary menu, so I think you have 'primary' as name of a menu location | |
Aug 15, 2019 at 5:50 | comment | added | noobron | I tried this, but it didn't work. Was printing the Array at two places. One at random page location (I know it's because of the 'print_r' ststement). But the other one was at the menu location. I guess it might have replaced the menu object with PHP Array object. On debugging more, I found out that this '$menu' variable inside the function definition was empty Array object. | |
Aug 14, 2019 at 22:19 | history | answered | Manyang | CC BY-SA 4.0 |