From c8d36d55e44c9d2e75bf8c4fe5236eb1c462ceba Mon Sep 17 00:00:00 2001 From: David Hoese <david.hoese@ssec.wisc.edu> Date: Mon, 27 Jan 2020 13:49:26 -0600 Subject: [PATCH] Add CORS header to times CGI script --- mapserver/cgi-bin/layer_times.py | 1 + 1 file changed, 1 insertion(+) diff --git a/mapserver/cgi-bin/layer_times.py b/mapserver/cgi-bin/layer_times.py index 68f0757..8666f0b 100755 --- a/mapserver/cgi-bin/layer_times.py +++ b/mapserver/cgi-bin/layer_times.py @@ -9,5 +9,6 @@ with fiona.open(layer, 'r') as shp_file: times = [x['properties']['time'] for x in shp_file] print("Content-Type: application/json") +print("Access-Control-Allow-Origin: *") print() # blank line, end of headers print(json.dumps(times)) -- GitLab