new user problem

Ed McNierney ed at TOPOZONE.COM
Sat Apr 2 05:50:57 PST 2005


Ferencik -

You didn't follow the instructions I gave you the first time you asked.
You changed your IMAGEURL from a URL to a file path, and that's why you
see the path to the PNG file.  Your IMAGEURL should not have been
changed from the original value you were using when you first asked the
question - it should be just "tmp".

The URL for a MapServer image in browse mode is created by adding the
filename of the generated file to the string in the IMAGEURL statement.
If you modify the IMAGEURL, you'll see that the URL to the PNG file in
the generated HTML output changes.  Just chang the IMAGEURL until the
generated URL is correct and pointing to the images.

You are getting an "error message" - the broken link icon is telling you
that the file can't be found!

     - Ed

Ed McNierney
President and Chief Mapmaker
TopoZone.com / Maps a la carte, Inc.
73 Princeton Street, Suite 305
North Chelmsford, MA  01863
Phone: +1 (978) 251-4242
Fax: +1 (978) 251-1396
ed at topozone.com

-----Original Message-----
From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of Ferencik Ioan
Sent: Saturday, April 02, 2005 5:52 AM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: [UMN_MAPSERVER-USERS] new user problem

Hi list,

i still have some problems with mapserver. I created a mapfile wich I
can in map mode with IE6 or Firefox. Though, in browse mode i see only
a blank picture, instead of PNG file itself I see a path to that PNG
file. When I click on map it doesn't give me any error it seems taht the
aplication is capable of panning. I do not understand what is happenning
because I don't receive any error message.

I use folowing map file:

MAP
  IMAGETYPE PNG24
  #EXTENT 349932 529491 358227 537108 # extent alba
  EXTENT 388605 583929 398798 590500
  FONTSET "fonts/fonts.list"
  SIZE 1000 1000
  SHAPEPATH "date"
  IMAGECOLOR 255 255 255
  TEMPLATEPATTERN "index"
  NAME "raster"
  PROJECTION
   "init=epsg:31700"
  END
  # Start of LAYER DEFINITIONS
---------------------------------------------
  LAYER # layer de tip raster
        NAME dem
        DATA "cluj.tif"
        TYPE RASTER
        PROJECTION
                 "init=epsg:31700"
         END
         STATUS default
         PROCESSING "BANDS=1,2,3"
   END #--sfarsit layer de tip raster
  LAYER # States polygon layer begins here
    NAME test
    DATA strazi
    STATUS DEFAULT
    TYPE LINE
    PROJECTION
      "init=epsg:31700"
    END
    #CLASSITEM "NAME"
    LABELITEM "NAME"
    CLASS

      COLOR 255 255 255
      LABEL
      COLOR 0 0 0
        TYPE TRUETYPE
        FONT arial
        SIZE 8

        POSITION LL
        PARTIALS true
        MINDISTANCE 300
        #BUFFER 4
      END
    END
  END

  # End of LAYER DEFINITIONS -------------------------------
        WEB
                IMAGEPATH "c:\ms4w\rosia\tmp\"
                IMAGEURL "c:\ms4w\rosia\tmp\"
                TEMPLATE 'index.html'
                LOG mslog.txt

        END


END # end of map file/object


and this is my template file:


<!-- MapServer version 4.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG
OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF SUPPORTS=PROJ SUPPORTS=FREETYPE
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER
SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER INPUT=POSTGIS INPUT=OGR
INPUT=GDAL INPUT=SHAPEFILE --> <html> <title> Aplicatie
Mapserver</title> <body> <FORM action="/cgi-bin/mapserv.exe"
method="GET" >
  <input type="hidden" name="map" value="c:\ms4w\rosia\raster.map" >
  <input type="hidden" name="imgext" value="368891.738000 604053.336000
379084.738000 614246.336000">
  <input type="hidden" name="imgxy" value="500 500">
  <input type="hidden" name="zoom" value="1">
  <input type="hidden" name="mode" value="browse">

  <p align="center" style="border: 1px dashed red;   "> Aplicatie
Mapserver</p><hr>
  <div align="center" style="border: 1px dashed red; width: 502px;
height:
502px; ">

        <input type="image"  name="img"
value="c:\ms4w\rosia\tmp\raster11124387134088.png" width="500"
height="500">



  </div>


</FORM>


</body>







</html>

Can anyone give me a hint?
Thanks in advance


_____________________________________________
Castiga peste 1000 de premii cu Wella Design!
http://wella.boom.ro



More information about the MapServer-users mailing list