Created
December 15, 2011 10:32
-
-
Save couraudt/1480648 to your computer and use it in GitHub Desktop.
.htacces
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ---------------------------------------------------------------------- | |
# Cross-domain AJAX requests | |
# ---------------------------------------------------------------------- | |
# Serve cross-domain Ajax requests, disabled by default. | |
# enable-cors.org | |
# code.google.com/p/html5security/wiki/CrossOriginRequestSecurity | |
# <IfModule mod_headers.c> | |
# Header set Access-Control-Allow-Origin "*" | |
# </IfModule> | |
# ---------------------------------------------------------------------- | |
# CORS-enabled images (@crossorigin) | |
# ---------------------------------------------------------------------- | |
# Send CORS headers if browsers request them; enabled by default. | |
# developer.mozilla.org/en/CORS_Enabled_Image | |
# blog.chromium.org/2011/07/using-cross-domain-images-in-webgl-and.html | |
# hacks.mozilla.org/2011/11/using-cors-to-load-webgl-textures-from-cross-domain-images/ | |
<IfModule mod_setenvif.c> | |
<IfModule mod_headers.c> | |
SetEnvIf Origin ":" IS_CORS | |
Header set Access-Control-Allow-Origin "*" env=IS_CORS | |
</IfModule> | |
</IfModule> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment