askdesign
5/26/2015 - 10:28 PM

Navigation Techniques

Code Snippets

/*-- Bill Erickson's subpages as secondary menu plug-in --*/
http://www.billerickson.net/genesis-subpages-as-secondary-menu/

/*-- The actual plugin --*/
https://wordpress.org/plugins/genesis-subpages-as-secondary-menu/

note: probably will try with Nicole Bernstein's website and THC website
/* --- Primary Nav Before Footer --- */
/*--- http://wpsites.net/wordpress-admin/nav-menu-genesis-footer/ ---*/

/*--- Display Primary Nav Menu Before Footer ---*/
/** Primary nav menu before footer */
remove_action( ‘genesis_after_header’, ‘genesis_do_nav’ );
add_action( ‘genesis_before_footer’, ‘genesis_do_nav’ );
/* --- Navigation --- */
RT @mlane: 10 Awesome CSS #Navigation Menu Creation Tutorials - 12.22.11
http://mln.im/ve7wve

/* --- CSS3 Dropdown Menus - 6.4.10 --- */
http://www.webdesignerwall.com/tutorials/css3-dropdown-menu/

/* --- Elegant Drop Menu with CSS only   -*/
http://aext.net/2009/09/elegant-drop-menu-with-css-only/
/* --- 50 Examples of Drop-Down Nav Menus in Web Designs - 7.9.10 --- */
http://sixrevisions.com/design-showcase-inspiration/50-examples-of-drop-down
-navigation-menus-in-web-designs/
/* --- @srikat’s responsive menu code  --- */
How to add News Pro's mobile responsive menu in other Genesis themes 
wp.me/p12qob-vD #GenesisWP
A collection of CSS3 powered hover effects to be applied to links, buttons, logos, SVG, featured images and so on. Easily apply to your own elements, modify or just use for inspiration. Available in CSS, Sass, and LESS.
http://ianlunn.github.io/Hover/
//* Add a custom class to li elements having children
//* Add this in child theme’s functions.php:

//* Add a custom class for menu items having children
//* Source: https://gist.github.com/devinsays/5210667

function add_menu_parent_class( $items ) {

   $parents = array();
   foreach ( $items as $item ) {
       if ( $item->menu_item_parent && $item->menu_item_parent > 0 ) {
           $parents[] = $item->menu_item_parent;
       }
   }

   foreach ( $items as $item ) {
       if ( in_array( $item->ID, $parents ) ) {
           $item->classes[] = 'has-children';
       }
   }

   return $items;
}
add_filter( 'wp_nav_menu_objects', 'add_menu_parent_class' );

.main-navigation li::before {
    color: #fff;
    content: "/";
    display: block;
    font-size: 16px;
    font-weight: 300;
    margin-right: -3px;
    margin-top: -9px;
    position: absolute;
    right: 0;
    top: 50%;
}

/* --- nothing on left side for 1st menu item --- */
.main-navigation li:first-child {
      content: "";
}