htaccess question
- Started
- Last post
- 3 Responses
- uan
how do I add more domains to this htaccess thing:
<FilesMatch "\.(ttf|otf|woff|eot)$">
<IfModule mod_headers.c>
Header set Access-Control-Allow-Origin "http://www.mydomain.com"
</IfModule>
</FilesMatch>I want to have www.mydomain.com and mydomain.com and myotherdomain.com in it.
- Continuity0
I would assume adding 'Header set Access-Control-Allow-Origin' for each domain for a total of four lines would do the trick, wouldn't it?
- uan0
done that, didn't work :(...
I'm looking at this code now (from google searches):
<FilesMatch "\.(otf|ttf)$">
SetEnvIf Origin "^http(s)?://(.+\.)?(sub\.domain... origin_is=$0
Header set Access-Control-Allow-Origin %{origin_is}e env=origin_is
</FilesMatch>wish I knew more about this htaccess thing.
- uan0
<FilesMatch "\.(ttf|otf|woff|eot)$">
SetEnvIf Origin "^http(s)?://(.+\.)?(sub\.domain... origin_is=$0
Header set Access-Control-Allow-Origin %{origin_is}e env=origin_is
</FilesMatch>this works!
- < http://pastebin.com/…
for complete code. for any further reference :)uan
- < http://pastebin.com/…