Still on Example 1.9 --same here!

Andreas Ritterbusch aritterbusch at YAHOO.COM
Wed Apr 13 06:55:30 PDT 2005


Hi: Not to hi-jack Lawal's thread too much... but I got the
exact same problem (and I'm sure this has come up in the past,
but unfortunately I can't get into the archives).

In other words, if someone answers Lawal's question, he/she
would make more than one new UMNer very, very happy.

Having said that, I now allow myself to include my .html file
and .map file (both clipped to save some bandwidth). Note that I
ended up using full paths, since nothing made this thing work. I
use Windows.

All my static maps work fine and it's just a path problem that I
can't seem to figure out.



First the .MAP file:

MAP
NAME           EX1.9_
IMAGETYPE      PNG24
EXTENT         201621.496941 -294488.285333 1425518.020722
498254.511514 # LAEA
#EXTENT         -97.5 41.619778 -82.122902 49.38562 # Geographic
SIZE           400 300
SHAPEPATH      "C:/ms4w/Apache/htdocs/tutorial/data"
SYMBOLSET
"C:/ms4w/Apache/htdocs/tutorial/symbols/symbols35.sym"
FONTSET        "C:/ms4w/Apache/htdocs/tutorial/fonts/fonts.list"

WEB
  TEMPLATE  'C:/ms4w/Apache/htdocs/tutorial/example1-9.html'
  IMAGEURL  '/tmp/'
  IMAGEPATH 'C:/ms4w/Apache/htdocs/tutorial/tmp/'
  #IMAGEURL  'http://localhost/tmp/'
  #IMAGEPATH '/data/tmp/'
END

PROJECTION
#  "proj=laea"
#  "ellps=clrk66"
#  "lat_0=45"
#  "lon_0=-100"
#
# Alternatively, you can specify an EPSG code.
 "init=epsg:2163"
#
END
...etc...etc...etc...




Now the .HTML file:

<html>
<head>
<title>MapServer 4.0 Tutorial</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<link type="text/css" rel="stylesheet" href="ms35.css" />
</head>

<body bgcolor="#FFFFFF" text="#000000">
<table align="center" width="600" border="0">
<tr>
<td>
<h3 align="center">MapServer Tutorial:<br />
        Example 1.8</h3>
      <div align="center">
          <img border="1"
src="http://localhost/cgi-bin/mapserv40?map=C:/ms4w/Apache/htdocs/tutorial/example1-9.map&mode=map"
/>
      </div>
      <p align="left">The map above was created in
"map" mode. It is
        a static map.</p>

          <!-- START OF MAPSERVER FORM -->
      <form name="mapserv" method="GET"
action="http://localhost/cgi-bin/mapserv40">
        <!-- HIDDEN MAPSERVER CGI VARIABLES -->
        <input type="hidden" name="map" value="[map]">
        <input type="hidden" name="imgext" value="[mapext]">
        <input type="hidden" name="imgxy" value="199.5 149.5">
        <input type="hidden" name="zoom" value="1">
        <input type="hidden" name="mode" value="browse">
                <div align="center">
                  <table border="1" cellpadding="0" cellspacing="0">
                    <tr><td>
                          <!-- THE INTERACTIVE, DYNAMICALLY CREATED MAP -->
                          <input type="image" name="img" src="[img]" width="400"
height="300">
                        </td></tr>
                  </table>
                </div>
          </form>
...etc...etc...etc...

Thanks a lot in advance,

Andreas.



__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/



More information about the MapServer-users mailing list