Cross Origin Request Error

When receiving a cross-origin / cross original request, CORS header 'Access-Control-Allow-Origin' does not match, or same origin disallow policy error you may need to add an http header to allow the request. The following two examples work in cases regarding Apache and may be used by adding one set to the .htaccess file:

 

<FilesMatch ".(js|css|xml|gz|html|eot|ttd|otf|woff)$">
Header add Access-Control-Allow-Origin "*"
</FilesMatch>

 

<IfModule mod_headers.c>
Header add Access-Control-Allow-Origin "*"
</IfModule>
  • 129 Users Found This Useful

Was this answer helpful?

Related Articles

Common Search Engine Optimization Tips

Get other websites to link to you. Have your website linked and posted in socal media...

Error 406 unacceptable

This error can be caused by several factors. One cause can be the incorrect permissions are set...

How to create a temporary 302 redirect via htaccess

An easy way to create a temporary redirect from one page to another web page is to use the 302...

How to use SharedSSL

SharedSSL is now available with our Ultra Unlimited. It is not as professional looking as having...

Can I change my username?

Usernames are setup in the manner for security. Most programs will allow you to save the...