<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
Thanks for the reply. Yes my layer is called '250'. Do you think this could be a problem?<BR>&nbsp;<BR>My mapfile layer&nbsp;looks as follows:<BR>
&nbsp;<BR>
&nbsp;LAYER<BR>&nbsp; <BR>&nbsp;&nbsp;&nbsp; NAME "250"<BR>&nbsp;&nbsp;&nbsp; METADATA<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; '250' "wms_demo"<BR>&nbsp;&nbsp;&nbsp; END<BR>&nbsp;&nbsp;&nbsp; STATUS ON<BR>&nbsp;&nbsp;&nbsp; TYPE raster<BR>&nbsp;&nbsp;&nbsp; TILEINDEX "250K"<BR>&nbsp;&nbsp;&nbsp; TILEITEM "Location"<BR>&nbsp;&nbsp;&nbsp; PROJECTION<BR>&nbsp;&nbsp;'proj=longlat'<BR>&nbsp;&nbsp;'ellps=WGS84'<BR>&nbsp;&nbsp;'datum=WGS84'<BR>&nbsp;&nbsp;'no_defs'<BR>&nbsp;&nbsp;''<BR>&nbsp;&nbsp;&nbsp; END<BR>&nbsp;&nbsp;&nbsp; CLASS<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; STYLE<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 0 0 0<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; END<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; LABEL<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 0 0 0<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SIZE SMALL<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; END<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; END<BR>&nbsp;&nbsp;&nbsp; <BR>
&nbsp; END<BR>&nbsp;&nbsp;<BR>&nbsp;&nbsp;As i mentioned it displays fine when status DEFAULT but does not display when Status ON. Any ideas where i am going wrong?<BR>
&nbsp;<BR>
Thanks<BR>&nbsp;<BR>&gt; Date: Tue, 13 Oct 2009 20:21:08 -0500<BR>&gt; Subject: Re: [mapserver-users] Calling WMS layer via openlayers when STATUS ON<BR>&gt; From: punk.kish@gmail.com<BR>&gt; To: mapserver-users@lists.osgeo.org<BR>&gt; <BR>&gt; On Tue, Oct 13, 2009 at 6:37 PM, Paul Curran &lt;paul_everton@hotmail.com&gt; wrote:<BR>&gt; &gt; Hi, Ive been struggling with this problem for a little while now.<BR>&gt; &gt;<BR>&gt; &gt; My WMS layer will only display if STATUS is set to DEFAULT within the<BR>&gt; &gt; mapfile. If status is set to ON, i get following error message within OL Map<BR>&gt; &gt; window. "WMSLoadGetMapParams(): WMS Server Error". What am i missing to call<BR>&gt; &gt; the layer within openlayers?<BR>&gt; &gt;<BR>&gt; &gt; My Code is as follows:<BR>&gt; &gt;<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; var bounds = new OpenLayers.Bounds(0, 0, 660046, 1229782);<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; var map, layer1, layer2;<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; var options = { maxExtent: bounds, maxResolution: 1000, numZoomLevels:<BR>&gt; &gt; 10};<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; function init(){<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; map = new OpenLayers.Map('map', options);<BR>&gt; &gt;<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; layer1 = new OpenLayers.Layer.WMS("OpenLayers WMS",<BR>&gt; &gt;<BR>&gt; &gt; "http://localhost/cgi-bin/mapserv.exe?map=c:/ms4w/apps/openlayers-2.8/data/uk2.map",<BR>&gt; &gt; { layers: "250" },<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {gutter: 15});<BR>&gt; &gt;<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; map.addLayer(layer1);<BR>&gt; &gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; map.zoomToMaxExtent();<BR>&gt; &gt;<BR>&gt; &gt;<BR>&gt; <BR>&gt; What is the name of your layer? Is it "250"? Is that a valid name?<BR>&gt; <BR>&gt; <BR>&gt; &gt; &nbsp;Thanks for any help in advance<BR>&gt; &gt;<BR>&gt; &gt; Paul<BR>&gt; &gt;<BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; -- <BR>&gt; Puneet Kishor http://www.punkish.org<BR>&gt; Carbon Model http://carbonmodel.org<BR>&gt; Charter Member, Open Source Geospatial Foundation http://www.osgeo.org<BR>&gt; Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor<BR>&gt; Nelson Institute, UW-Madison http://www.nelson.wisc.edu<BR>&gt; -----------------------------------------------------------------------<BR>&gt; Assertions are politics; backing up assertions with evidence is science<BR>&gt; =======================================================================<BR>&gt; Sent from Madison, WI, United States<BR>&gt; _______________________________________________<BR>&gt; mapserver-users mailing list<BR>&gt; mapserver-users@lists.osgeo.org<BR>&gt; http://lists.osgeo.org/mailman/listinfo/mapserver-users<BR><BR>                                               <br /><hr />Chat to your friends for free on selected mobiles. <a href='http://clk.atdmt.com/UKM/go/174426567/direct/01/' target='_new'>Learn more.</a></body>
</html>