Viewing 2 replies - 1 through 2 (of 2 total)
  • Theme Author ThemeAWESOME

    (@tsquez)

    Hi there,

    I was working on a snippet to do this very thing. When I get home later I will look at the snippet and probably publish it for you or post it here.

    Sorry for the wait. In the mean time you may want to do a search on how to do queue functions, especially with a child theme.

    Keep in mind though this is a “how to” question. I usually do not answer how to questions here in the support forums. If possible email me if your not signed up for the newsletter.

    Theme Author ThemeAWESOME

    (@tsquez)

    Hey there, sorry for the delayed response. I have decided that I will post how to do this here for anyone else who may be interested.

    First thing, you need to make sure you are using a child theme.

    Second, open the functions.php file of the child theme and add the following:

    function remove_open_sans() {
    	remove_action( 'wp_enqueue_scripts', 'wpforge_google_fonts', 0);
    }
    add_action( 'after_setup_theme', 'remove_open_sans', 9 );

    this will remove Open-Sans from WP-Forge.

    Now you can add your own Google font by adding the following (I am going to use Oswald font as an example):

    if ( ! function_exists( 'my_theme_fonts' ) ) {
    	function my_theme_fonts() {
    	    // register the font styles we want
    	    wp_enqueue_style('wpforge-opensans', '//fonts.googleapis.com/css?family=Oswald');
    	}
    	add_action( 'wp_enqueue_scripts', 'my_theme_fonts', 0);
    }

    Now you can name the function whatever you want and use whatever Google font you want.

    Hope this helps everyone. If possible please leave a rating and review for WP-Forge.

    Thanks again.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Dequeue Open Sans font’ is closed to new replies.