I have created a MapThat Layer which uses a WMS layer from an internal GeoServer instance, but when I try to display the layer the map hangs – saying ‘Loading’:
There are likely two reasons for this:
1 – Check that URL you are using in your Layer SQL is using the IP Address/DNS alias for the server that GeoServer resides on. Usually when checking that a WMS layer has worked, we preview the layer in OpenLayers via GeoServer. If you do this while on the web server, then the URL provided will use a ‘Localhost’ reference e.g.:
So to resolve this, you should ensure that the MapThat Layer SQL uses the IP address, or preferably a DNS alias for that Server e.g.. Now by using the correct server reference in your Layer SQL the layer will render in MapThat.
Note – that when you use the URL reference from OpenLayers, you will need to edit the end reference so that it renders the WMS as an image in MapThat. Simply replace the =application/openlayers with = image/png2 – The second option that you may have missed, is that when rendering external WMS layers, we have added the option to allow you to render the whole WMS as one tile, or to render as induvial tiles. This setting is stored in the Render_As_Tile field in the VE_Layers table. For your internal GeoServer layers ensure you set this value to be ‘Y’.
Your WMS layers from your GeoServer instance will now render in MapThat.