Thanks, I tried as you suggested after reading the documentation<div><br></div><div>    WEB<br>        IMAGEPATH "/opt/test/static/ms_tmp"<br>        IMAGEURL  "/media/ms_tmp/"</div><div><div>        METADATA</div>
<div>            ows_enable_request "*"</div><div>        END</div>    END # WEB</div><div><br></div><div>But I still get the same error.</div><div><br></div><div>Thanks</div><div>Mike<br><br><div class="gmail_quote">
On Thu, Oct 25, 2012 at 5:02 PM, Rahkonen Jukka <span dir="ltr"><<a href="mailto:Jukka.Rahkonen@mmmtike.fi" target="_blank">Jukka.Rahkonen@mmmtike.fi</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
Perhaps you have not added<br>
"ows_enable_request" "*"<br>
into your mapfile. Search and read the migration guide if this happens to be the reason for the trouble.<br>
<br>
Mapserver web site should be updated at least.<br>
<span class="HOEnZb"><font color="#888888"><br>
-Jukka Rahkonen-<br>
<br>
________________________________<br>
</font></span><div class="HOEnZb"><div class="h5">Mike Stoddart wrote:<br>
<br>
> I'm using MapServer 6.0.1 on Fedora 16 and I'm having a weird layer issue. We're trying to port our application from MapServer 5 -> 6 and we're seeing the error:<br>
<br>
> WMS server error. Invalid layer(s) given in the LAYERS parameter.<br>
<br>
> I can re-create the problem using Python MapScript and an example map file from the MapServer website. The map file is:<br>
<br>
MAP<br>
    NAME "sample"<br>
    STATUS ON<br>
    SIZE 600 400<br>
<br>
    EXTENT -180 -90 180 90<br>
    UNITS DD<br>
<br>
    IMAGECOLOR 255 255 255<br>
    FONTSET        "/opt/test/conf/fonts.list"<br>
<br>
    #<br>
    # Start of web interface definition<br>
    #<br>
    WEB<br>
        IMAGEPATH "/opt/test/static/ms_tmp"<br>
        IMAGEURL  "/media/ms_tmp/"<br>
    END # WEB<br>
<br>
    #<br>
    # Start of layer definitions<br>
    #<br>
LAYER<br>
 NAME 'inline_circles'<br>
 TYPE CIRCLE<br>
 STATUS on<br>
 FEATURE<br>
   POINTS<br>
     74.01 -53.8<br>
     110.7 -22.16<br>
   END<br>
 END<br>
 CLASS<br>
   STYLE<br>
     COLOR 0 0 255<br>
   END<br>
 END<br>
END<br>
<br>
END # MAP<br>
<br>
If I use the following Python:<br>
<br>
import mapscript<br>
f = "<path to map file>"<br>
m = mapscript.mapObj(f)<br>
r = mapscript.OWSRequest()<br>
r.setParameter('LAYERS', 'inline_circle')<br>
m.loadOWSParameters(r)<br>
<br>
I get:<br>
<br>
...<br>
<ServiceExceptionReport version="1.1.1"><br>
<ServiceException code="LayerNotDefined"><br>
msWMSLoadGetMapParams(): WMS server error. Invalid layer(s) given in the LAYERS parameter.<br>
</ServiceException><br>
</ServiceExceptionReport><br>
Traceback (most recent call last):<br>
  File "<stdin>", line 1, in <module><br>
  File "/usr/lib64/python2.7/site-packages/mapscript.py", line 1623, in loadOWSParameters<br>
    def loadOWSParameters(*args): return _mapscript.mapObj_loadOWSParameters(*args)<br>
_mapscript.MapServerError: msWMSLoadGetMapParams(): WMS server error. Invalid layer(s) given in the LAYERS parameter.<br>
<br>
<br>
So it doesn't think the layer exists. If I check the layer's status:<br>
<br>
m.getLayer(0).status<br>
0<br>
<br>
The layer is disabled? So I'm assuming something is amiss in my map file but I just can't see it. Am I missing something obvious?<br>
<br>
Thanks<br>
Mike<br>
<br>
</div></div></blockquote></div><br></div>