views:

376

answers:

1

Just wanted a confirmation for this: Firefox currently doesn't play well for picking custom fonts through a sub-domain via the font-face tag. Other browsers do this without any problems.

A little research showed up saying that i am required to set the Access-Control-Allow-Origin as is shown in the link here: http://pastie.org/653265

Essentially i have my blog at kaushikgopal.com/blog and i was trying to access fonts that within this blog that are available at font.kaushikgopal.com. I tried changing the same in my .htaccess file but couldn't resolve the issue.(I placed a .htaccess file within the font sub-domain folder and directly pasted code from the above pastie link).

I submitted a ticket to dreamhost asking for assistance and they were helpful in clearly stating "We do not support Access-Control-Allow-Origin on shared hosting servers".

So i didn't go the sub-domain route for fonts. But i'm a little curious, has anyone tried this (with a dreamhost hosting account would be helpful)? Just want to confirm what the tech-support guy suggested is accurate and there's no other way.

Thanks.

Another nice link clearly stating the problem : http://www.stevesouders.com/tests/font-face/xdomain.php

+1  A: 

I just tried and it does work (on Dreamhost). Eg, /mysite/pub/.htaccess:

header add Access-Control-Allow-Origin *

See http://42at.com/lab/Thumboard/bookmarklet.html. The bookmarklet does an ajax call to my domain, and with above access-control is able to grab html snippet.

Moos