-
AuthorPosts
-
December 11, 2015 at 4:30 pm #551177
I can’t seem to get the CSS styling changes I’d like to make working. I’m not a coding expert but I’m pretty sure the below should work. What am I missing?
h2.avia-caption-title {
font-family: “Frontage Bold”;
color: red;
}December 11, 2015 at 4:59 pm #551191Hi Fleur!
Are you loading the Frontage Bold font, somehow?
I can see the web font exist here, https://github.com/seanwooj/free-d/tree/master/fonts
but have you uploaded to your ftp and created the CSS needed to use it?Thanks a lot
Cheers!
BasilisDecember 12, 2015 at 1:44 am #551328Hi Basilis
I have pasted the code provided by myfonts.com in my Google Analytics Tracking Code field, as instructed by Yigit. I’ve also pasted in the code below for your reference.
The trouble is, it’s not just this font that doesn’t seem to be working – I can’t seem to target any specific elements in my CSS, and I suspect it’s because everything is a class rather than a straight up H1 or H2.
For example, if I’m trying to change the font/size of the main heading on my home page, when I inspect the element, this is what I see: <h2 style=”font-size:110px; ” class=”avia-caption-title” itemprop=”name”>Fleur Murphy</h2>
I’m not great with coding but I thought it should be a simple matter of targeting that particular class using the following CSS, but maybe I’m wrong?
h2.avia-caption-title {
font-family: “Frontage Bold”;
color: red;
}By the way, I’m working from a child theme, and there is no other CSS in my style sheet.
+++
Paste this code into the <head> of your HTML to embed these fonts.
You are only permitted use of these webfonts for testing purposes in non-production environments for 30 days. You can apply them in your css using:
font-family: ‘Frontage Bold’
font-family: ‘Frontage’+++
<script type=”text/javascript”>
(function() {
var path = ‘//easy.myfonts.net/v2/js?sid=222386(font-family=Frontage+Bold)&sid=222389(font-family=Frontage)&key=ha27hZg2B2’,
protocol = (‘https:’ == document.location.protocol ? ‘https:’ : ‘http:’),
trial = document.createElement(‘script’);
trial.type = ‘text/javascript’;
trial.async = true;
trial.src = protocol + path;
var head = document.getElementsByTagName(“head”)[0];
head.appendChild(trial);
})();
</script>December 12, 2015 at 2:13 am #551349PS I’m trying to do this within style.css in my child theme.
December 12, 2015 at 2:47 am #551368Actually I’ve been working through this as I wait and have been able to find the correct class to work with. I am able to change everything except the font family. It just doesn’t seem to be reading/recognising the font. Hope you can help :)
December 12, 2015 at 9:47 am #551406Fixed it by removing the quotation marks…
December 14, 2015 at 8:05 am #551987 -
AuthorPosts
- You must be logged in to reply to this topic.