Adding Second Navigation

  • Posted in : Read WP
  • doublestop
    Participant

    Hey there!
    Great theme :) I’m tweaking a few things and I want to add a second menu underneath the main one. I found the code in functions.php to add a new drop down to the Theme Options editor. I basically want to add a new option so I can pick a Google Font for the category nav too.

    I added this (based on the main navigation):

    $wp_customize->add_setting( 'setting_cat_font', array(	'default' => 'Coustard',
    							'transport' => 'refresh' ) );
    
    $wp_customize->add_control( 'control_cat_font', array(	'label' => 'Cat Menu Font',
    							'section' => 'section_fonts',
    							'settings' => 'setting_cat_font',
    							'type' => 'select',
    							'choices' => $all_fonts ) );
    

    How do I tie that in to my category menu? Class for my Category navigation is “cat-navigation”

    I see the code being added to my header with the Google font – I just can’t figure out where that’s coming from.

    Also, is it easy to override the Google fonts if I want to use something non-Google? The code in the header was overriding anything I added to the stylesheet. I’d just like to know where that’s coming from in case I want to edit it.

    Thanks!!

    doublestop
    Participant

    Here’s the site I’m working on: http://doublestoptest.com/mm/

    ahmetsali
    Keymaster

    Hi, this is not easy to do with some lines of code. But alternatively you can change fonts of your second navigation via custom css;

    @import url(http://fonts.googleapis.com/css?family=Oxygen);
    
    .cat-navigation ul li { font-family: 'Oxygen', sans-serif; }
    

    Also you can add non google fonts via “Custom Css” box.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register