When using mapcache to my mapserver I am getting the following error.Access to
* XMLHttpRequest at 'http://192.168.112.225/mapcache/?SERVICE=WMS&REQUEST=GetCapabilities <http://192.168.112.225/mapcache/?SERVICE=WMS&REQUEST=GetCapabilities>' from origin 'http://192.168.115.38 <http://192.168.115.38>' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values '*, *', but only one is allowed.* I think this is caused by the fact that I have a forwarding rule in my mapcache.xml * <forwarding_rule name="catch all"> <http> <url>http://192.168.112.225/cgi-bin/mapserv?version=1.1.1&map=/usr/lib/cgi-bin/osm-bw.map <http://192.168.112.225/cgi-bin/mapserv?version=1.1.1&map=/usr/lib/cgi-bin/osm-bw.map></url> </http>* * </forwarding_rule>* and in my apache.conf I have this *<Directory /> Header add Access-Control-Allow-Origin "*" Options FollowSymLinks AllowOverride None Require all denied* *</Directory>--* So one of the Access-Control-Allow-Origin comes from the apache server for the GetCapabilities call and then another is added because the forwarding_rule adds the header as well. What is a good way to get around this. I tried to just add the access-Control-Allow-Origin rule on the mapcache path but it did not work. http://www.atlantageek.com
_______________________________________________ MapServer-users mailing list [email protected] https://lists.osgeo.org/mailman/listinfo/mapserver-users
