- This topic has 5 replies, 2 voices, and was last updated 3 years ago by Tom.
May 1, 2018 at 6:22 am #564542Stephen
I’ve been following this guide:
Font files are uploaded to my child theme folder and I intend to use the code below. I think its good to go, but not sure about the line in bold?
src: url(‘https://www.domain.com/wp-content/themes/generatepress_child/fonts/din_regular-webfont.woff2’) format(‘woff2’), /* Super Modern Browsers */
url(‘https://www.domain.com/wp-content/themes/generatepress_child/fonts/din_regular-webfont.woff’) format(‘woff’); /* Pretty Modern Browsers */
src: url(‘https://www.domain.com/wp-content/themes/generatepress_child/fonts/din_bold-webfont.woff2’) format(‘woff2’), /* Super Modern Browsers */
url(‘https://www.domain.com/wp-content/themes/generatepress_child/fonts/din_bold-webfont.woff’) format(‘woff’); /* Pretty Modern Browsers */
url(‘https://www.domain.com/wp-content/themes/generatepress_child/fonts/din_bold-webfont.ttf’) format(‘truetype’), /* Safari, Android, iOS */
Also, what is the best way to add the CSS to my child theme stylesheet please? I’m not a coder. Should I use Customiser – Additional CSS or can I do it in WP?
SteveGeneratePress 2.0.2GP Premium 1.6.2May 1, 2018 at 9:21 pm #565093TomLead DeveloperLead Developer
Sorry for not getting back to you sooner!
What about that line aren’t you sure about?
Since you’re using a child theme anyways, you can add it in the style.css file within your child theme.May 2, 2018 at 5:01 am #565318Stephen
I’m just not sure if the bold text is needed anymore? Most web font sites that I found only convert to woff and woff2. Is .ttf needed?
SteveMay 2, 2018 at 9:21 am #565629TomLead DeveloperLead Developer
That totally depends on what kind of browser support you need. You’re likely right that it isn’t needed, unless you need to support older versions of IE.May 2, 2018 at 11:10 am #565746Stephen
Thanks Tom.May 2, 2018 at 2:55 pm #565917
- You must be logged in to reply to this topic.