I am just starting to get Mapserver set up on Fedora Core 6, on a 1and1
dedicate droot server, managed via Plesk 8. I am testing with simple
"Hello World" template, calling a simple image file with just the "hello
world" string. Within a virtual host (set up by Dynamic Virtual Hosting
by Plesk) I have the paths /httpdocs/mapserver/hello.html,
httpdocs/mapserver/hello.map, httpdocs/mapserver/tmp/ and
/cgi-bin/mapserv. (template and map file shown below).

Mapserv returns an image file to the /tmp/ directory and returns the
correct image url to the template - but the image does not display. If I
copy the source into a new html file, in the same directory, it works
fine. Here is the img tag : <img
src="/tmp/Hello_World11816653009157.png" width=400 height=300 border =0>

 I am baffled. Any help much appreciated. 

TEMPLATE

<html>
<head><title>Mapserver Hello World</title></head>
<body>
        <form method = GET action ="/cgi-bin/mapserv">
        <input type ="submit" value="Click Me">
        <input type="hidden" name="map" value
="/var/www/vhosts/myvirtualhost.org.uk/httpdocs/mapserver/hello.map"
        <input type="hidden" name="map_web_imagepath" value
="/var/www/vhosts/myvirtualhost.org.uk/httpdocs/mapserver/tmp/"
        </form>
        
</body>
</html>
        
MAP FILE

NAME "Hello_World"
SIZE 400 300
IMAGECOLOR 249 245 186
IMAGETYPE png
EXTENT -1.00 -1.00 1.00 1.00
WEB
        TEMPLATE
"/var/www/vhosts/myvirtualhost.org.uk/httpdocs/mapserver/hello.html"
        IMAGEPATH
"/var/www/vhosts/myvirtualhost.org.uk/httpdocs/mapserver/tmp/"
        IMAGEURL "/tmp/"
END

LAYER
        STATUS default
        TYPE point
        FEATURE
                POINTS 0.0 0.0 END
                TEXT "Hello World "
        END #end feature
        CLASS
                STYLE
                        COLOR 255 0 0
                END
                LABEL
                        TYPE bitmap
                END
        END
END
END

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.472 / Virus Database: 269.8.14/845 - Release Date:
12/06/2007 06:39
 

Reply via email to