[Mapserver-users] Re: [ms4w-users] Help,How to publish vector maps
Tyler Mitchell
tjmitchell at riverside.bc.ca
Wed Jul 28 09:56:30 PDT 2004
Isaac, try a really simple example first. Then add more layers.
Also it helps to try to use shp2img on the command line with your map file
first. That helps isolate whether it's a web server problem or a map file
problem.
I see some lines in your map file that start with "!" - what is that?
Tyler
ms4w-users-bounces at lists.maptools.org wrote on 07/27/2004 06:02:55 PM:
> Hello,
> I am trying to publish vector data but the output map did not show
> up.Below is the code for my map file.Could any of you help me out?
> MAP
> NAME "GERMAN"
> STATUS ON
> EXTENT -2200000 -712631 3072800 3840000
> SIZE 400 300
> SHAPEPATH "./germany"
> SYMBOLSET "./etc/symbols.sym"
> FONTSET "./etc/fonts.txt"
> IMAGETYPE PNG
> IMAGECOLOR 255 255 255
> UNITS METERS
> #
> # Start of web interface definition
> #
> WEB
> MINSCALE 2e+06
> MAXSCALE 5e+07
> #
> # On Windows systems, /tmp and /tmp/ms_tmp/ should be created at the
root
> # of the drive where the .MAP file resides.
> #
> IMAGEPATH "/ms4w/tmp/ms_tmp/"
> IMAGEURL "/ms_tmp/"
> END
> #
> # Start of reference object (keymap)
> #
> # REFERENCE
> # STATUS ON
> # IMAGE "images/keymap.png"
> # SIZE 100 75
> # EXTENT -2.2e+06 -712631 3.0728e+06 3.84e+06
> # COLOR -1 -1 -1
> # OUTLINECOLOR 255 0 0
> # MINBOXSIZE 3
> # MAXBOXSIZE 0
> # MARKER 0
> # MARKERSIZE 0
> # END
> #
> # Start of querymap object
> #
> QUERYMAP
> STATUS OFF
> SIZE -1 -1
> COLOR 255 0 0
> STYLE HILITE
> END
> #
> # Start of legend object
> #
> LEGEND
> STATUS ON
> IMAGECOLOR 255 255 255
> POSITION LL
> KEYSIZE 18 12
> KEYSPACING 5 5
> TEMPLATE "ttt"
> LABEL
> TYPE BITMAP
> SIZE MEDIUM
> OFFSET 0 0
> BUFFER 0
> MINDISTANCE -1
> MINFEATURESIZE -1
> COLOR 0 0 89
> PARTIALS TRUE
> FORCE FALSE
> END
> END
> #
> # Start of scalebar object
> #
> SCALEBAR
> STATUS ON
> COLOR 255 255 255
> OUTLINECOLOR 0 0 0
> BACKGROUNDCOLOR 0 0 0
> IMAGECOLOR 255 255 255
> UNITS KILOMETERS
> INTERVALS 5
> SIZE 150 5
> STYLE 0
> POSITION LL
> LABEL
> TYPE BITMAP
> SIZE SMALL
> OFFSET 0 0
> BUFFER 0
> MINDISTANCE -1
> MINFEATURESIZE -1
> COLOR 0 0 0
> PARTIALS TRUE
> FORCE FALSE
> END
> END
>
> #
> # Start of OutputFormat object
> #
> OUT! PUTFORMAT
> NAME "png"
> MIMETYPE "image/png"
> DRIVER "GD/PNG"
> EXTENSION "png"
> IMAGEMODE PC256
> TRANSPARENT FALSE
> END
> #
> # Start of layer definitions
> #
> LAYER
> NAME "deu_city"
> STATUS ON
> DATA "deu_city"
> TYPE POINT
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS
> METADATA
> "DESCRIPTION" "German Cities"
> END
> END # Layer
>
> LAYER
> NAME "deu_dist"
> STATUS ON
> DATA "deu_dist"
> TYPE POLYGON
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS
> METADATA
> "DESCRIPTION" "German Districts"
> END
> CLASS
> ! NAME "German Districts"
> STYLE
> SYMBOL 0
> COLOR 240 240 240
> OUTLINECOLOR 199 199 199
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
>
> LAYER
> NAME "deu_lake"
> STATUS ON
> DATA "deu_lake"
> TYPE POLYGON
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS
> METADATA
> "DESCRIPTION" "German Lakes"
> END
> ! CLASS
> NAME "German Lakes"
> EXPRESSION /16|21/
> STYLE
> SYMBOL 0
> COLOR 225 249 255
> OUTLINECOLOR 186 234 245
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
>
> LAYER
> NAME "deu_regn"
> STATUS ON
> DATA "deu_regn"
> TYPE POLYGON
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS
> METADATA
> ! "DESCRIPTION" "Region In Germany"
> END
> CLASS
> NAME "Regions In Germany"
> EXPRESSION "0"
> STYLE
> SYMBOL 0
> COLOR 225 249 255
> OUTLINECOLOR 186 234 245
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
>
> LAYER
> NAME "deuriver"
> STATUS ON
> DATA "deuriver"
> TYPE LINE
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> ! TOLERANCEUNITS PIXELS
> METADATA
> "DESCRIPTION" "River In Germany"
> END
> CLASS
> NAME "Rivers In Germany"
> STYLE
> SYMBOL 0
> COLOR 120 120 120
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
>
> LAYER
> NAME "deuinter"
> STATUS ON
> DATA "deuinter"
> TYPE LINE
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS METADATA
> "DESCRIPTION" "Inter In Germany"
> END
> CLASS
> NAME "Inter In Germany"
> STYLE
> SYMBOL 3
> COLOR 0 119 255
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
>
> LAYER
> NAME "deustate"
> STATUS OFF
> DATA "deustate"
> TYPE POLYGON
> UNITS METERS
> SIZEUNITS PIXELS
> TOLERANCE 0
> TOLERANCEUNITS PIXELS
> METADA! TA
> "DESCRIPTION" "States In Germany"
> END
> CLASS
> NAME "States In Germany"
> STYLE
> SYMBOL 0
> COLOR 168 0 184
> SIZE 1
> MINSIZE 1
> MAXSIZE 100
> END
> END
> END # Layer
> END # Map File
>
>
> Isaac Kwadwo Nti
> Kaiser Str.19,
> 76131 Karlsruhe
> Germany.
> Home Tel: +497213529267
> Mobile : +491798846336
>
> The new MSN 8: smart spam protection and 2 months FREE*
> _______________________________________________
> ms4w-users mailing list
> ms4w-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/ms4w-users
More information about the MapServer-users
mailing list