Skip to content

WordPress plugin to create an ACF custom field type for selecting WordPress menus.

Notifications You must be signed in to change notification settings

rjhartman/ACF-Menu-Select

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ACF Menu Field

Adds a WP menu selector custom field type to ACF. Will list all available WP menus and return the selected menu's slug.

Installation

  1. Copy the acf-menu-select folder into your wp-content/plugins folder
  2. Activate the menu plugin via the plugins admin page
  3. Create a new field via ACF and select the 'Menu Selector' type under the 'Choice' category
  4. When using in the front end, be sure to get the menu object, the field will simply return the menu identifier string.

Front-end example:

Wordpress

  wp_get_nav_menu_object(get_field('custom_menu'));

Timber (timber.php, page.php, etc..)

  $context['custom_menu'] = new Timber\Menu(get_field('custom_menu'));

About

WordPress plugin to create an ACF custom field type for selecting WordPress menus.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages