Changeset 760430
- Timestamp:
- 08/21/2013 11:15:46 PM (13 years ago)
- Location:
- advanced-custom-fields-nav-menu-field
- Files:
-
- 2 edited
-
tags/1.1.2/readme.txt (modified) (1 diff)
-
trunk/readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
advanced-custom-fields-nav-menu-field/tags/1.1.2/readme.txt
r760422 r760430 55 55 == Frequently Asked Questions == 56 56 57 = Can you show a quick example of how to use this? = 58 59 Sure can! 60 61 1. Create a new field group 62 2. Add a Nav Menu and set the Field Label to `Side Menu` (this will cause the Field Name to be `side_menu`) 63 3. Set the Nav Menu's Return Value to `Nav Menu HTML` 64 4. Set the Location Rules to Show if "Post Type" "is equal to" "Page" 65 5. Save the Field Group 66 6. Now in your themes sidebar.php, put the following code before or after any of the div's with class="widget-area" 67 ` 68 <?php if( get_field( 'side_menu' ) ) : ?> 69 <div class="widget-area"> 70 <?php the_field( 'side_menu' ); ?> 71 </div> 72 <?php endif; ?> 73 ` 74 Finally, create or edit a page, select a menu in the Side Menu field, and view the page to see that menu in the sidebar! 75 57 76 = Will you make this plugin compatible with Advanced Custom Fields v3? = 58 77 -
advanced-custom-fields-nav-menu-field/trunk/readme.txt
r760422 r760430 55 55 == Frequently Asked Questions == 56 56 57 = Can you show a quick example of how to use this? = 58 59 Sure can! 60 61 1. Create a new field group 62 2. Add a Nav Menu and set the Field Label to `Side Menu` (this will cause the Field Name to be `side_menu`) 63 3. Set the Nav Menu's Return Value to `Nav Menu HTML` 64 4. Set the Location Rules to Show if "Post Type" "is equal to" "Page" 65 5. Save the Field Group 66 6. Now in your themes sidebar.php, put the following code before or after any of the div's with class="widget-area" 67 ` 68 <?php if( get_field( 'side_menu' ) ) : ?> 69 <div class="widget-area"> 70 <?php the_field( 'side_menu' ); ?> 71 </div> 72 <?php endif; ?> 73 ` 74 Finally, create or edit a page, select a menu in the Side Menu field, and view the page to see that menu in the sidebar! 75 57 76 = Will you make this plugin compatible with Advanced Custom Fields v3? = 58 77
Note: See TracChangeset
for help on using the changeset viewer.