Getting ready

MapServer uses PROJ.4 (https://trac.osgeo.org/proj/) for projection management. This library does not exist by default with the Spherical Mercator projection (EPSG:900913) defined. Such a projection is commonly used by commercial map API providers, such as GoogleMaps, Yahoo! Maps, and Microsoft Bing, and can provide excellent base layers for your maps.

For this recipe, we need to have under consideration the following:

  1. Due to security restrictions in JavaScript, it is not possible to retrieve information from remote domains using XMLHttpRequest. You will encounter this issue in the recipe when you send a WMS GetFeatureInfo request to a GeoServer that is typically running on Tomcat at port 8080 and also send a request from an ...

Get PostGIS Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.