Header always set Access-Control-Allow-Origin "*"

Post Reply
prasadgudi
Posts: 1
Joined: Sat Oct 06, 2018 2:43 pm

Header always set Access-Control-Allow-Origin "*"

Post by prasadgudi » Tue Oct 16, 2018 7:03 am

how to set this header 'Access-Control-Allow-Origin "*" ' for origin (http://domain.com)

surjit
Site Admin
Posts: 27
Joined: Thu Jan 25, 2018 11:30 am

Re: Header always set Access-Control-Allow-Origin "*"

Post by surjit » Wed Oct 17, 2018 1:13 pm

header('Access-Control-Allow-Origin: *');
header('Access-Control-Allow-Methods: GET, POST, PATCH, PUT, DELETE, OPTIONS');
header('Access-Control-Allow-Headers: Origin, Authorization, Content-Type, X-Auth-Token');

Post Reply