How do Google web fonts working on Mozilla Firefox, while other cross-domain @ embed fonts not work?

I used Google's built-in web font, not using the default javascript code provided by Google, but using the @ font-face css code present in the dynamic javascript file. It worked great with Mozilla Firefox.

Now when I try to use a web font downloaded from Font Squirrel, it does not work in Mozilla Firefox. I used the same @ font-face css code as the google web font service, but it does not work in Firefox.

I know about it in Firefox

Firefox (which supports @ font-face from version 3.5) does not allow the use of cross-domain fonts by default. This means that the font must be filed from the same domain (and subdomain).

If so, how can Google handle cross-domain web fonts?

+5
source share
2 answers

For cross-domain fonts running in Firefox, you need to serve them with the Access-Control-Allow-Origin header , which allows the application domain to be hosted from

+5
source

Google can do this because their servers allow domain sharing. The server that hosts the fonts (and the css font) on the controls with which it shares. It makes sense?

+3
source

All Articles