- This topic is empty.
-
AuthorPosts
-
September 29, 2013 at 5:06 pm #151646
John Nolan
ParticipantI’m having a problem getting H&FJ’s cloud fonts to work consistently on my blog:
http://www.ragandbone.ca/wp/index.phpSometimes they work, sometime they don’t. Sometimes I see them in Chrome, but if I then load the page into Safari they’re gone, or vice-versa.
A validation check shows 403 errors for the font files, but I think that’s due to the protected nature of the font resources. (This site shows the same error, and so does H&F’s own site.
I contacted H&FJ, but haven’t received any real pointers except to say that I needed to put their code in the head. Hmm…
In general, the fonts are unreliable…any ideas where I’m going wrong?
October 2, 2013 at 4:50 am #151887John Nolan
ParticipantJust to follow up:
I got help from H&FJ. They said:
“It sounds like there may be an issue related to the project’s domain list, so if it’s not too much trouble I’d like you to add your domain as a wildcard (“*.ragandbone.ca”) through your Cloud dashboard, which will allow webfonts to render across all subdomains.”That seems to have solved my problems.
October 2, 2013 at 9:42 pm #151928chrisburton
ParticipantWorks for me too but your type choices are a bit all over the place.
October 3, 2013 at 4:37 am #151940John Nolan
ParticipantWell, I was leaving old choices in place until I got the fonts working consistently.
October 4, 2013 at 1:59 am #152003chrisburton
ParticipantOh, I see. Glad you figured it out.
November 27, 2013 at 5:15 pm #157268mgauthier15
ParticipantJust found this thread as I am encountering the same problem.
John – which file did you paste the code they supplied into? Was it as simple as pasting their code? Or did you have to modify the function.php file in your child theme?
Also, how do you add your domain as a wildcard through their service? So far, H&FJ hasn’t been so helpful (as I’m sure you have encountered).
Many thanks in advance for any help you can give!
November 27, 2013 at 7:16 pm #157273John Nolan
ParticipantI added the code to the function.php of the theme parent, and then also added a function.php file to the child theme, editing some other code I found. I don’t know if both were necessary, I was just trying whatever I could think of. (And I really have very little idea what I was doing!)
The child theme’s function.php, in it’s entirety, is:
<?php
add_action( 'genesis_meta', 'wpb_add_google_fonts', 5);function wpb_add_google_fonts() {
echo '’;
}(replace the “###” with your H&fJ numbers)
Obviously I could/should have renamed the function, but I never thought anyone else would be looking!
I even tried writing a plugin:
But I think the main thing is the wildcard domain. Add a new domain to your project: *.yourdomain.com
That should do it!
November 27, 2013 at 9:03 pm #157278mgauthier15
Participant<?php add_action( 'genesis_meta', 'wpb_add_google_fonts', 5); function wpb_add_google_fonts() { echo '’; } (replace the “###” with your H&fJ numbers)
By ### do you mean the “5”?
So you used a combination of google and H&FJ fonts? Where is the url for the php file to reference your font library on their server?
Thanks so much for your help!
November 28, 2013 at 3:22 am #157292John Nolan
ParticipantHmmm… I see that my post didn’t come through entirely (some of the code is missing.)
No, I just reused a bit of code that was originally used to load google fonts, but I didn’t re-name the function in the code. It doesn’t really matter what the function is called.
I’ll try again. The child theme’s function.php, in it’s entirety, is:
<?php
add_action( ‘genesis_meta’, ‘add_hfj_fonts’, 5);function add_hfj_fonts() {
echo ‘place_hfj_css_key_here” />’;
} -
AuthorPosts
- The forum ‘Other’ is closed to new topics and replies.