[mapserver-users] msLoadMap() Unable to access file

Burgholzer,Robert rwburgholzer at deq.virginia.gov
Fri May 16 08:28:52 EDT 2008


The only thing I can see initially, Is tht you may want to change the
IMAGEURL slashes in your mapfile to "/tmp/" instead of "\tmp\".

 

Robert W. Burgholzer

Surface Water Modeler

Office of Water Supply and Planning

Virginia Department of Environmental Quality

rwburgholzer at deq.virginia.gov

804-698-4405

Open Source Modeling Tools:

http://sourceforge.net/projects/npsource/

-----Original Message-----
From: mapserver-users-bounces at lists.osgeo.org
[mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of
nipapada at gmail.com
Sent: Thursday, May 15, 2008 4:48 PM
To: mapserver-users at lists.osgeo.org
Subject: [mapserver-users] msLoadMap() Unable to access file

 

Hello.

I try to run an example i found in B. Kropla's book (Beginning MapServer
- Open Source GIS Development) in windows XP.
I create a hello.html template which is placed in htdocs folder of the
Apache server.
Also, hello.map is placed in htdocs folder as well.
The contents of hello.html are:

<html>
          <head><title>MapServer Hello World</title></head>
          <body>
                    <form method=POST action="\cgi-bin\mapserv.exe">
                              <input type="submit" value="Click Me">
                              <input type="hidden" name="map"
value="hello.map">
                              <input type="hidden"
name="map_web_imagepath" value="c:\ms4w\Apache\htdocs\tmp\">
                    </form>
                    <IMG SRC="[img]" width=400 height=300 border=0>
</body>
</html>

The conents of hello.map are:

#This is our "Hello World" mapfile
NAME "Hello_world"
SIZE 400 300
IMAGECOLOR 249 245 186
IMAGETYPE png
EXTENT -1.00 -1.00 1.00 1.00
WEB
    TEMPLATE "c:\ms4w\Apache\htdocs\hello.html"
    IMAGEPATH "c:\ms4w\Apache\htdocs\tmp\"
    IMAGEURL "\tmp\"
END
LAYER
    STATUS default
    TYPE point
    FEATURE
        POINTS 0.0 0.0 END
        TEXT "Hello World"
    END
    
    CLASS
        STYLE
            COLOR 255 0 0
        END
        LABEL
            TYPE bitmap
        END
    END
    END
END
    


When i click on "Click me" button i get the message msLoadMap() Unable
to access file hello.map.
Furthemore,when i move hello.map in cgi-bin folder of the Apache server
and change the corresponding line in hello.html
to  <input type="hidden" name="map" value="cgi-bin\hello.map"> 
i get the message 

loadWeb(): Unknown identifier. Parsing error near (C):(line 1)
 
 
Furthemore,when i open hello.html instead of getting just the click-me
button i get the following:
 
 
 

\par \lang1033\f1 \lang1032\f0  \par \lang1033\f1 \lang1032\f0  \par
\lang1033\f1 \lang1032\f0  \par \lang1033\f1 \lang1032\f0 

\par \lang1033\f1 \lang1032\f0 \par \par \par } 

 


I have read other mail on the same problem but i could not figure it
out.
Thank you.

Nikos Papadakis
Department of Computer & Communications Engineering
Univercity of Thessaly.








-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-users/attachments/20080516/08376456/attachment-0001.html


More information about the mapserver-users mailing list