font-awesome-sass-rails
font-awesome-sass-rails copied to clipboard
Icons not loading in Firefox production server
The icons display properly in all browsers but Firefox. I'm currently using Cloudfront and Nginx. Here is my CORS configuration:
<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<AllowedHeader>*</AllowedHeader>
</CORSRule>
</CORSConfiguration>
Any ideas?
Is there any error in Web Console? If not, use HttpFox to inspect HTTP may be a good way to find the problem.
I'm getting this in HttpFox:
00:00:05.069 0.398 493 0 GET (Aborted) NS_BINDING_ABORTED https://d1c1ae4w0mx7a2.cloudfront.net/assets/fontawesome-webfont-a0fbd98b232e7e1ef9cdaad813b26eb3.woff
Did some Google research. Is the following relevant to your problem? https://forums.aws.amazon.com/thread.jspa?threadID=103402
It looks like there's a vary origin issue, but aws is still in the process of implementing it.
a brief lookup reveals: https://github.com/netdna/bootstrap-cdn/issues/27 can it be arranged the font would load from a cdn? (otherwise, i'll have to find a way to add the header to s3's response — or ditch this gem completely; either is very unfortunate)
Also having this issue.
+1
I've correctly set my CORS configuration for S3, and now Firefox works.
Feel free to use my font URL for testing, but don't abuse this: https://s3.amazonaws.com/nbt-assets/lib/fontawesome/font/fontawesome-webfont.woff
Umm, I'm sorry, haven't quite checked it atm, does this http://www.bootstrapcdn.com/#tab_fontawesome work?
@costa yes with that CDN it work
got the issue too
We discussed getting the font-awesome-rails gem working on CDNs and with Firefox here:
https://github.com/bokmann/font-awesome-rails/pull/27
Along with the embedded code in that issue, does switching to the font-awesome-rails gem fix the issues discussed here?
Of course, the bootstrapcdn is a great solution too.