Control Web Panel

WebPanel => CentOS 7 Problems => Topic started by: mrr-r on February 04, 2020, 09:21:39 AM

Title: How to add Cors for apache & nginx without error?
Post by: mrr-r on February 04, 2020, 09:21:39 AM
hello,
How to add Cors for apache & nginx without error?
please help!
Title: Re: How to add Cors for apache & nginx without error?
Post by: rcschaff on February 06, 2020, 02:26:45 AM
Apache is easy: https://enable-cors.org/server_apache.html

Nginx is a bit more painful.  You have to set it in all locations as I am aware.
Check out this article.    They recommend creating a file with the parameters, and including it in the top of each server block.  On CWP, DO NOT name it .conf, or it will crash the server. 

try cors.include or something like that.