[mapserver-users] Connecting to remote MapServer WMS/WMF layers using PHP/OpenLayers

Eric Jarvies 7 at ericjarvies.com
Fri Jan 21 19:12:47 EST 2011


Hello,

I am attempting to connect to a remote MapServer( http://www.catastroloscabos.gob.mx/cgi-bin/mapserv.fcgi?map=/home/juribe/webcatastro/catastro.map& ) and retrieve the respective WMS layers.  However, I am unable to do so for some reason.

http://loscabosproperties.mx/geoserver/wms.png

I get the result in XML format, and the map is not displayed.

The remote MapServer server is located at:
http://www.catastroloscabos.gob.mx/cgi-bin/mapserv.fcgi?map=/home/juribe/webcatastro/catastro.map&

In my PHP/OpenLayers doc/code, i have this:

        var wmsUrl2 = "http://www.catastroloscabos.gob.mx/cgi-bin/mapserv.fcgi";
        var wms2 = new OpenLayers.Layer.WMS("WMS2",
            wmsUrl2,
            { map: '/home/juribe/webcatastro/catastro.map',
            //layers: 'p',
            //map_imagetype: 'jpg'
            SERVICE: 'WMS',
            VERSION: '1.1.1',
            REQUEST: 'GetCapabilities'
            },
            {singleTile: true, isBaseLayer: false});
        map.addLayer(wms2);

Any help would be appreciated.  Thanks!




-------------- next part --------------
Skipped content of type multipart/related


More information about the mapserver-users mailing list