- This topic has 5 replies, 2 voices, and was last updated 2 years, 11 months ago by
Tom.
-
AuthorPosts
-
February 10, 2020 at 3:59 am #1160388
Michael
Hi guys,
Yes, it’s that time again – another weird issue from me. This makes no sense to me at all. On my privacy page (and it seems like only on the privacy page) I am getting a bunch of console errors for the fonts, which then aren’t loading properly. This can’t be local or it would be on every page I would guess? Here is the page in question:
https://www.reclaimdesign.org/privacy-policy.html
Here are the console errors (in Chrome):
Access to font at 'https://reclaimdesign.org/wp-content/uploads/fonts/open-sans-v17-latin-regular.woff2' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin. VM212 privacy-policy.html:156 GET https://reclaimdesign.org/wp-content/uploads/fonts/open-sans-v17-latin-regular.woff2 net::ERR_FAILED VM212 privacy-policy.html:1 Access to font at 'https://reclaimdesign.org/wp-content/themes/generatepress/fonts/generatepress.woff2' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin. VM212 privacy-policy.html:156 GET https://reclaimdesign.org/wp-content/themes/generatepress/fonts/generatepress.woff2 net::ERR_FAILED privacy-policy.html:1 Access to font at 'https://reclaimdesign.org/wp-content/uploads/fonts/icomoon.ttf' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin. privacy-policy.html:504 GET https://reclaimdesign.org/wp-content/uploads/fonts/icomoon.ttf net::ERR_FAILED privacy-policy.html:1 Access to font at 'https://reclaimdesign.org/wp-content/plugins/gp-premium/general/icons/gp-premium.ttf' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin. privacy-policy.html:1 GET https://reclaimdesign.org/wp-content/plugins/gp-premium/general/icons/gp-premium.ttf net::ERR_FAILED privacy-policy.html:1 Access to font at 'https://reclaimdesign.org/wp-content/uploads/fonts/open-sans-v17-latin-italic.woff2' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin. jquery.js?ver=1.12.4-wp:3 GET https://reclaimdesign.org/wp-content/uploads/fonts/open-sans-v17-latin-italic.woff2 net::ERR_FAILED
Please can anyone shed some light on how to go about fixing?
February 10, 2020 at 11:11 am #1160932Tom
Lead DeveloperLead DeveloperHi there,
This happens when the URL serving the resource (in this case, a font), is different than the URL you’re visiting.
For example, let’s look at the error:
Access to font at 'https://reclaimdesign.org/wp-content/uploads/fonts/open-sans-v17-latin-regular.woff2' from origin 'https://www.reclaimdesign.org' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'https://reclaimdesign.org' that is not equal to the supplied origin.
Notice how the font is checking for
https://reclaim...
, but the origin ishttps://www.reclaim..
That
www
is triggering the error.You need to make sure your WordPress install is set to the same URL you’re visiting. It’s also a good idea to redirect www to non-www (or the other way around) to prevent this kind of issue.
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/
Ongoing Development: https://generatepress.com/ongoing-developmentFebruary 10, 2020 at 11:20 am #1160944Michael
Hi Tom, thank you for looking at this for me. In my WP dashboard both the WordPress Address (URL) and the Site Address (URL) are set to https://reclaimdesign.org
Please can you tell me how I can redirect www as you mention?
February 10, 2020 at 11:21 am #1160946Tom
Lead DeveloperLead DeveloperYour hosting can typically do this. You want them to set up a
301
redirect from www to non-www. It’s a pretty standard thing they should be able to take care of quickly ๐Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/
Ongoing Development: https://generatepress.com/ongoing-developmentFebruary 10, 2020 at 11:22 am #1160948Michael
Thank you Tom I will ask them about that
February 10, 2020 at 3:10 pm #1161103Tom
Lead DeveloperLead DeveloperNo problem ๐
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/
Ongoing Development: https://generatepress.com/ongoing-development -
AuthorPosts
- You must be logged in to reply to this topic.