[Resolved] SNipet to add multiple Google Fonts

Home Forums Support [Resolved] SNipet to add multiple Google Fonts

Home Forums Support SNipet to add multiple Google Fonts

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1060056
    John

    Hello again,

    I am trying to add multiple Google Fonts using the Snippets and method as described here:
    https://docs.generatepress.com/article/customizing-the-google-font-list/

    This has worked totally fine for one font.

    But I am doing something wrong with adding the second font.
    I added a second snippet, but the snippet broke the site…saying it was repeating the code:

    PHP Fatal error: Cannot redeclare tu_add_google_fonts() (previously
    declared in
    /home/jl_webalchemy/staging.pivotacupt.com/wp-content/plugins/code-snippets/php/ snippet-ops.php(361)
    : eval()’d code:2) in
    /home/jl_webalchemy/staging.pivotacupt.com/wp-content/plugins/code-snippets/php/ snippet-ops.php(361)
    : eval()’d code on line 10

    Can you guide me in how to add more than one font to the customiser please?

    And how can I remove this info from the plugin, as every time I delete and reinstall, it pulls the old info through and crashes the site again.
    Right now I have to rename the plugin via FTP to get the site to load.

    Cheers!
    john

    #1060080
    Leo
    Staff
    Customer Support

    Hi there,

    Try this:
    https://generatepress.com/forums/topic/add-2-or-3-custom-google-font/#post-915819

    Let me know if this helps ๐Ÿ™‚

    #1060142
    John

    Thank you – that worked a treat

    #1060782
    Leo
    Staff
    Customer Support

    No problem ๐Ÿ™‚

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.