ThemeShaper Forums » Thematic

[closed]

Responsive Menu

(34 posts)
  • Started 2 years ago by bogh
  • Latest reply from bogh
  • This topic is not resolved
  1. nice share. i'll have to check that out at some point.

    Posted 2 years ago #
  2. bogh
    Member

    :)

    I am still finding issues with it, and maybe you will find more.

    Please help me with this one:
    I have done this to add a the "nav" class to the "ul"

    function Aeryn_menu_args( $args ) {
    $args = array(
    	'menu_class' => 'nav sf-menu',
    	'container_class' => 'menu'
    	);
    return $args;
    }
    add_filter( 'thematic_nav_menu_args', 'Aeryn_menu_args' );

    But I can't do the same for "thematic_page_menu_args", because in it's case 'menu_class' is the class for the DIV above the UL.

    Thanks.

    Posted 2 years ago #
  3. yeah i ran into that myself the other day for another reason. but the solution is actually in how thematic handles it:

    // Add ID and CLASS attributes to the first <ul> occurence in wp_page_menu
    function add_menuclass($ulclass) {
    return preg_replace('/<ul>/', '<ul class="yourclass">', $ulclass, 1);
    }
    add_filter('wp_page_menu','add_menuclass');
    Posted 2 years ago #
  4. bogh
    Member

    You saved me again :)
    Thank you.

    Posted 2 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.