geoadmin / mf-geoadmin3

Legacy source code of map.geo.admin.ch
https://map.geo.admin.ch
Other
227 stars 72 forks source link

Wmts Stadt-Zurich.ch not displaying #5094

Closed davidoesch closed 2 years ago

davidoesch commented 4 years ago

Try to load öffentliche Parkplätze via Import

https://www.ogd.stadt-zuerich.ch/mapproxy/wmts/1.0.0/WMTSCapabilities.xml

Result Not working

https://s.geo.admin.ch/863df01640

pakb commented 4 years ago

image Is that what it should output? If so, maybe verify out of Bund network (I'm on my 4G and this is what I get)

p1d1d1 commented 4 years ago

In Bund net working in FF, not working in EDGE

pakb commented 4 years ago

Well, then it's out of the scope of what I can manage. I'm closing this.

davidoesch commented 4 years ago

Nope : it does not work on safari Chrome on ios13

pakb commented 4 years ago

image that's why.

pakb commented 4 years ago

TL;DR; we don't do cookies on geoadmin, either they allow access to their data without cookie acceptance, or we can't show their data

But there's something fishy, we are redirected to this page CookieCheck... But if I access image directly from iOs Safari, I don't get any CookieCheck weird stuff

procrastinatio commented 4 years ago

The same doc on https://www.procrastinatio.org/WMTS/WMTSCapabilities.ZH.xml works well.

pakb commented 4 years ago

So CORS related?! And I haven't seen your line : "We're in 2019 and people don't know how to do CORS"?! 😄

procrastinatio commented 4 years ago

@pakb Partly. The thing is even in 2019, many external servers are still correctly configured for CORS. We make a HEAD request, and decide if we have to use or not our proxy to get the resource.

In my view the two options are

davidoesch commented 4 years ago

CORS on Desktop no issue but on mobile... to complex for me

gemetris commented 4 years ago

Hello. I have the same (or similar) issue with a "private" WMS service published by ArcGIS Enterprise/Portal. I'm getting a CORS error with Chrome or Edge. Problem seems to be related to the proxy used by GeoAdmin. In some other geoportals I tested, it works.

It says me "Access to XMLHttpRequest at 'https://service-proxy.prod.bgdi.ch/https...' from origin 'https://map.geo.admin.ch' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource."

But if I add an explicite 'Access-Control-Allow-Origin' rule at my side (should not be needed I think), I'm getting "Access to XMLHttpRequest at '...' from origin 'https://map.geo.admin.ch' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values 'https://map.geo.admin.ch, *', but only one is allowed.

I'm not sure where the problem is (perhaps ArcGIS adds automatically request URL to response (map.geo.admin.ch)), but anyway this headers seem be make problem with your proxy https://service-proxy.prod.bgdi.ch (not detected or then multiple).

Is this ticket still at work? Best regards and thanks

Note: the WMS service I'm trying to use is not really public and at this time only for tests purposes at my side, it's why I dont write the URL here. But if needed I can give you the URL somehow!

davidoesch commented 2 years ago

works