Skip to content Skip to sidebar Skip to footer

How To Set Header Access-control-allow-origin For Xdomain

How to set header Access-Control-Allow-Origin for XDomain i am trying to do this by java code or by script code. Please suggest me some way.

Solution 1:

Here's all the information you need to enable CORS.

The easiest way to do it is by creating an .htaccess file inside the directory that you want to serve with the headers with this line:

Header set Access-Control-Allow-Origin *

In the link above, you can find plenty other methods. I'm sure some of them should suit you.

Post a Comment for "How To Set Header Access-control-allow-origin For Xdomain"