[OpenLayers-Users] WMS Map request

Bart van den Eijnden (OSGIS) bartvde at osgis.nl
Tue Jul 6 02:02:54 EDT 2010


Hi,

use singleTile: true and ratio: 1 in your layer options.

Best regards,
Bart

> Hi Group,
>
> I am trying to configure my WMS service with OpenLayers. My script looks
> below
>
> <script type="text/javascript">
>    //var map = new OpenLayers.Map('map',{maxResolution: 1000} );
>    var map = new OpenLayers.Map('map', {
>       maxExtent: new OpenLayers.Bounds(
> -638480920.244,-188017611.367,665489491.580,1019789790.73), maxResolution:
> 500 } );
>    var wmsURL = "
> http://localhost:8080/gss/ogc?version=1.3.0&crs=sw:nsw_trans_mercator_mm";
>    var myLayer = new OpenLayers.Layer.WMS( 'CE SL' , wmsURL , { layers:
> 'background', styles: 'Default' } , { buffer: 1 , isBaseLayer: true } );
>    map.addLayer( myLayer );
>    map.zoomToMaxExtent();
>   </script>
>
>
> It should actually send only one WMS request for the first time and then
> act
> according to uses operations like Pan , Zoom. But, that is not how it's
> working. Everytime when I open this html file, it's sending 48 WMS
> requests
> and creating 48 image files in the resources folder and none of these
> images
> are turned up on the browser. Also, surprisingly all those 48 images are
> empty with just white background.
>
> Does any one what the problem is ?
>
> Thanks,
> Kalyan
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>





More information about the Users mailing list