[QGIS-Developer] "GetMap" URL from WMS layers
jmckenna at gatewaygeomatics.com
Tue Mar 31 07:54:08 PDT 2020
Try Richard's great 'QGIS Network Logger' plugin, to see all WMS
requests. I've recorded several options here to grab the GetMap url:
MapServer Consulting and Training Services
On 2020-03-31 11:37 a.m., Jakob Miksch wrote:
> Dear list,
> I want to extract the "GetMap" URL from WMS layers. For most of the WMS
> layers I can extract it from "layer.source()". However this does not
> work for WMS layers where "GetMap" and "GetCapabilities" is different.
> Like for this layer:
> The only place where I can find the "GetMap" URL is inside the
> "layer.htmlMetadata()" document. From there the URL can be extracted
> using REGEX. But every localization of QGIS (e.g. German, French ...)
> have different terms for the surrounding "GetMap" HTML element. This
> makes this approach quite tricky.
> Is there any more elegant solution how to retrieve the "GetMap" URL from
> WMS layers?
> Thanks in advance and best wishes,
More information about the QGIS-Developer