Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Register footer menus as theme locations #2506

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

stduerre
Copy link
Contributor

Summary

Register footer menus so they are available as positions in WordPress admin.

Currently, the menus in the footer (Footer Primary, Footer Secondary, Social) are only defined by naming convention. That doesn't work for multilingual setups because menu names are unique and menus that work with the master theme can not be created in more than one language at a time. Registering the menu as theme locations enabled the use of WordPress admin to select what menus to show in the footer, independent of menu names.

If no menu is set for the location, the old naming convention is still in use to ensure backwards compatibility.

Testing

  1. Make sure existing menus are still shown in the footer after installing this update (backwards compatibility)
  2. Create or edit menus and assign them to the appropriate theme locations
  3. Make sure the menus display correctly

Register footer menus so they are available as theme locations in WordPress admin.
@stduerre stduerre marked this pull request as ready for review January 20, 2025 14:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants