[mapserver-users] mapfile help

Walt Lin joemayfair at usa.net
Tue Sep 25 22:08:40 PDT 2001


Hey guys,

I'm having trouble turning on some layers with mapscript.  When turning on the "county" layer, mapscript complains, returns a -1 status, and does not turn it on.  The strange thing was that it used to, and I'm almost positive I didn't change the mapfile entry for that layer, just added new layers and moved things around.  Do you see anything wrong with my mapfile the way it is?  I've read the docs but can't seem to figure it out.  The layers are tiger files converted to shp.  Thanks.

Walt

MAP
  STATUS ON
#   EXTENT -72.70  41.44 -70.28  42.79

  imagecolor 255 255 255
#  SIZE 421 281
  UNITS dd
  FONTSET fonts.list
#  MARKERSET marker.sym

  LAYER
    NAME county
    TYPE POLYGON
  #  TOLERANCE 3
    MAXSCALE 4000000
    MINSCALE 5000
    LABELMAXSCALE 4000000
    LABELITEM "NAME"
    CLASS
      COLOR 255 255 255
      BACKGROUNDCOLOR 255 255 255
      OUTLINECOLOR 200 200 200
      LABEL
        ANGLE AUTO
        COLOR 0 0 0
        TYPE TRUETYPE
        FONT arial
        SIZE 10
        POSITION AUTO
        WRAP " "
        MINDISTANCE 300
      END
    END
  END

  LAYER
    NAME states
    TYPE POLYGON
    #TOLERANCE 3

    MAXSCALE 10000000000
    MINSCALE 2000000
    LABELMAXSCALE 4000000
    LABELITEM "Name"
    CLASS
      COLOR 255 255 255
      BACKGROUNDCOLOR 255 255 255
      OUTLINECOLOR 200 200 200
      LABEL
        ANGLE AUTO
        COLOR 0 0 0
        TYPE TRUETYPE
        FONT arial
        SIZE 10
        POSITION AUTO
        WRAP " "
        MINDISTANCE 300
      END
    END
  END





  LAYER
    NAME roads
    TYPE LINE
    MAXSCALE 185000
    LABELMAXSCALE 180000
    LABELITEM "FENAME"
    CLASS
      backgroundcolor 255 255 255
      COLOR 180 180 180      
      LABEL
	ANGLE AUTO
	COLOR 0 0 0
	TYPE TRUETYPE
	FONT arial
	SIZE 10
	POSITION AUTO
	WRAP " "
	MINDISTANCE 300
      END
    END
  END
  LAYER
    NAME water
    TYPE POLYGON
    MAXSCALE 4000000
    TOLERANCE 3

    CLASS
      NAME "Water"
      COLOR 150 150 255
#      BACKGROUNDCOLOR 32 201 201
      BACKGROUNDCOLOR 150 150 255
      OUTLINECOLOR 150 150 255
    END
  END # layer
  LAYER
    NAME kgl
    TYPE POLYGON
    MAXSCALE 40000
    LABELMAXSCALE 40000
    LABELITEM "KGLNAME"
    CLASS
      NAME "Key"
      COLOR 0 250 125 
      OUTLINECOLOR 150 150 255
      LABEL
        COLOR 0 0 0
      END
    END
  END





END # end map



More information about the MapServer-users mailing list