• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Google Fonts – multiple fonts

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Google Fonts – multiple fonts

This topic is: resolved

Tagged: google fonts

  • This topic has 3 replies, 3 voices, and was last updated 8 years, 2 months ago by Landon.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • February 24, 2014 at 7:48 pm #92230
    BrendaGaelSmith
    Participant

    I am using the Prose theme and wish to load two different Google fonts - a script font for headings and a sans serif font for other text.

    I have successfully added one font via "Custom Code>Custom Functions" and following this tutorial:
    http://my.studiopress.com/tutorials/load-google-fonts/

    However, when I add a second font, the site will not load. What is the best way to load two different Google fonts?

    http://loisparishevans.com
    February 25, 2014 at 12:52 am #92262
    Peter
    Member

    You can use the vertical bar | symbol to list multiple fonts. For example:

    add_action( 'wp_enqueue_scripts', 'sp_load_google_fonts' );
    function sp_load_google_fonts() {
    wp_enqueue_style( 'google-font', '//fonts.googleapis.com/css?family=Lato:300,700|Open+Sans:400,700', array(), CHILD_THEME_VERSION );
    }

    You can add as many fonts as you want, just separate them with a vertical bar |

    February 25, 2014 at 2:00 am #92277
    BrendaGaelSmith
    Participant

    Thank you Peter. That works perfectly 🙂

    March 4, 2014 at 10:21 pm #93468
    Landon
    Member

    Thank you!

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Google Fonts – multiple fonts’ is closed to new replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2022 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble