Hi
I am trying to add two or more Googlefonts. I put this in the Child theme functions.php
add_filter( ‘avf_google_heading_font’, ‘avia_add_heading_font’);
function avia_add_heading_font($fonts)
{
$fonts[‘Cantarell’] = ‘Cantarell’;
return $fonts;
}
add_filter( ‘avf_google_content_font’, ‘avia_add_content_font’);
function avia_add_content_font($fonts)
{
$fonts[‘Cantarell’] = ‘Cantarell’;
return $fonts;
}
That worked fine. But when I put the same again, but with another font name) it crashed and produced a Fatal Error message. Adding any single font seems fine but more than one creates the error message.
Hey envapk2!
please refer to this post: https://kriesi.at/support/topic/adding-google-fonts-plural/#post-166980
Best regards,
Andy
Hi Andy
That’s great, many thanks
Peter