Tagged: x
-
AuthorPosts
-
March 30, 2016 at 3:14 am #858324
I tired adding to
customizer > Custom > css
@import url(https://fonts.googleapis.com/css?family=Stalemate);
Customizer > custom > Java
<script type=”text/javascript”>
WebFontConfig = {
google: { families: [ ‘Stalemate::latin’ ] }
};
(function() {
var wf = document.createElement(‘script’);
wf.src = ‘https://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js’;
wf.type = ‘text/javascript’;
wf.async = ‘true’;
var s = document.getElementsByTagName(‘script’)[0];
s.parentNode.insertBefore(wf, s);
})(); </script>In corner stone, i add
<span style=”font-size: 24px; font-family: ‘quicksand'”>text content</span>
it works
But when i add
<span style=”font-size: 24px; font-family: ‘Stalemate’, cursive;'”>text content</span>
It does not work.
March 30, 2016 at 3:15 am #858326This reply has been marked as private.March 30, 2016 at 4:21 am #858391Hi Nelson,
Please note that
<script>
tag is not needed on Customizer > Javascript. Please update the code to this:WebFontConfig = { google: { families: [ 'Allura::latin' ] } }; (function() { var wf = document.createElement('script'); wf.src = 'https://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js'; wf.type = 'text/javascript'; wf.async = 'true'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(wf, s); })();
For Stalemate, you don’t need to enclose it with the single quote like below:
<span style="font-size: 24px; font-family: Stalemate, cursive;">text content</span>
See attached image.Hope this helps.
March 30, 2016 at 8:31 am #858729WebFontConfig = {
google: { families: [ ‘Allura::latin’ ] }
};
(function() {
var wf = document.createElement(‘script’);
wf.src = ‘https://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js’;
wf.type = ‘text/javascript’;
wf.async = ‘true’;
var s = document.getElementsByTagName(‘script’)[0];
s.parentNode.insertBefore(wf, s);
})();====================================
I changed to the code you provided above.
I tried both the
text block method
<span style=”font-size: 24px; font-family: Stalemate, cursive;”>text content</span>Custom headline method
adding font-family: Stalemate to style======================================
Still does not work.
March 30, 2016 at 11:40 am #858968Hi there,
Thanks for updating. I can’t see the script on your Customizer – http://prntscr.com/am2stv
Would you clarify where you have added to load the font?
Cheers!
-
AuthorPosts