[Mapserver-users] MapServer Tutorial 4.0 Example 1.4 no image

Carol L Heydon carol_heydon at usgs.gov
Mon Feb 2 10:59:09 PST 2004


This is a multipart message in MIME format.
--=_alternative 006849E887256E2E_=
Content-Type: text/plain; charset="us-ascii"

I'm trying to work through Tutorial4.0 with MapServer 4.0 on Windows 2000. 
 I made the needed changes to the path information in the html and map 
files.  Everything works fine for Examples 1.1, 1.2, and 1.3, but from 1.4 
on the image does not display.  What's different beginning with example 
1.4?

data directory:  C:\Program Files\Apache 
Group\Apache2\htdocs\tutorial\data
mapserv40 located in:  C:\Program Files\Apache 
Group\Apache2\htdocs\cgi-bin

Mapfile:
MAP
  IMAGETYPE      PNG
  EXTENT         201621.496941 -294488.285333 1425518.020722 498254.511514
  SIZE           400 300
  SHAPEPATH      "data"
  IMAGECOLOR     255 255 255

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

  # Start of LAYER DEFINITIONS 
---------------------------------------------
  LAYER # States polygon layer begins here
    NAME         states_poly
    DATA         states_ugl
    STATUS       DEFAULT
    TYPE         POLYGON

    PROJECTION
      "init=epsg:4326"
    END

    CLASSITEM    "CLASS"
    CLASS
      EXPRESSION 'land'
       COLOR      232 232 232
    END
    CLASS
      EXPRESSION 'water'
       COLOR      198 198 255
    END
  END # States polygon layer ends here

  LAYER # States line layer begins here
    NAME         states_line
    DATA         states_ugl
    STATUS       DEFAULT
    TYPE         LINE

    PROJECTION
      "init=epsg:4326"
    END

    CLASSITEM    "CLASS"
    CLASS
      EXPRESSION 'land'
      COLOR      32 32 32
    END
  END # States line layer ends here
  # End of LAYER DEFINITIONS -------------------------------
END # end of map file

html:
<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">Example 1.4: Labeling the Map</h3>
      <div align="center"><img border="1" 
src="/cgi-bin/mapserv40?map=C:/Program Files/Apache 
Group/Apache2/htdocs/tutorial/example1-4.map&mode=map" />
      </div>
      <p align="left">We can also add labels to our map.</p>
      <hr>
      <p align="left">This is what the mapfile looks like:</p>
      <pre align="left">MAP
  IMAGETYPE PNG
  EXTENT 201621.496941 -294488.285333 1425518.020722 498254.511514
  SIZE 400 300
  SHAPEPATH "data"
  IMAGECOLOR 255 255 255
  FONTSET "fonts/fonts.list"

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

  # Start of LAYER DEFINITIONS 
---------------------------------------------
  LAYER # States polygon layer begins here
    NAME states_poly
    DATA states_ugl
    STATUS DEFAULT
    TYPE POLYGON

    PROJECTION
      "init=epsg:4326"
    END

    CLASSITEM "CLASS"
    LABELITEM "STATE"
    CLASS
      EXPRESSION 'land'
      COLOR 232 232 232
      LABEL
        COLOR 132 31 31
        SHADOWCOLOR 218 218 218
        SHADOWSIZE 2 2
        TYPE TRUETYPE
        FONT arial-bold
        SIZE 12
        ANTIALIAS TRUE
        POSITION CL
        PARTIALS FALSE
        MINDISTANCE 300
        BUFFER 4
      END # end of label
    END
  END # States polygon layer ends here

  LAYER # States line layer begins here
    NAME states_line
    DATA states_ugl
    STATUS DEFAULT
    TYPE LINE

    PROJECTION
      "init=epsg:4326"
    END

    CLASSITEM "CLASS"
    CLASS
      EXPRESSION 'land'
      COLOR 64 64 64
    END
  END # States line layer ends here
  # End of LAYER DEFINITIONS -------------------------------
END # end of map file</pre>
      <hr align="center" width="300">
      <p>Here we introduce a few more parameters along with the LABEL 
object:</p>
      <p>FONTSET<br>
        Here we specify the full path to our truetype fonts list (or font 
set)
        file. This file lists each of the available fonts. See the file 
itself
        and the <a 
href="http://mapserver.gis.umn.edu/doc40/fontset.html">MapServer
        fonset documentation</a> for more info. FONTSET is a parameter of 
the
        MAP object.</p>
      <p>LABELITEM<br>
        This specifies which data attribute to use for labeling, in this 
case
        "STATE". LABELITEM is a parameter of the LAYER 
object.</p>
      <p>LABEL<br>
        Marks the beginning of the LABEL object. The label object can be 
used
        under other objects (i.e. the SCALEBAR object).</p>
      <p> COLOR<br>
        Within the LABEL object, COLOR specifies the color of the label 
text.</p>
      <p>SHADOWCOLOR<br>
        This specifies the shadow color of the label text.</p>
      <p>SHADOWSIZE<br>
        Specifies the shadow size. The value corresponds to the X and the 
Y shifts
        in pixels. So, "2 2" means two pixels wide by two pixels 
high.</p>
      <p>TYPE<br>
        Within the LABEL object, TYPE specifies what type of font to use. 
We have
        the choice of TRUETYPE or BITMAP (the built-in fonts). We choose 
TRUETYPE.</p>
      <p>FONT<br>
        If you specify TYPE as TRUETYPE, you need to specify what font to 
use.
        The value here is the "alias" in the font list file.</p>
      <p>SIZE<br>
        If using truetype fonts, the value is size in pixels. If bitmap, 
you can
        say something like "small" or "large".</p>
      <p>ANTIALIAS<br>
        This turns truetype antialiasing on or off. Remember the value 
isn't on
        or off but TRUE or FALSE.</p>
      <p>POSITION<br>
        Where to position the label text in relation to the label points. 
The
        value is a combination of vertical and horizontal positions. You 
have
        the following choices for vertical alignment: C for center, U for 
upper,
        and L for lower. For horizontal alignment you have the following 
choices:
        C for center, L for left, and R for right. So, to align the label 
text
        to the center of label ID you'd use the value "CC" 
(center-center).
        Or if you'd like it to be on the lower left of the ID, you'd use 
LL. Another
        way is to let MapServer decide the best position for your labels. 
For
        this you would use the value "AUTO".</p>
      <p>PARTIALS<br>
        Tells MapServer whether to generate incomplete label texts or not. 
The
        default here is not to generate fragments of a label text. The 
value is
        either TRUE or FALSE.</p>
      <p>MINDISTANCE<br>
        This is the minimum distance in pixels between duplicate labels. 
See what
        happens if you increase or decrease this value.</p>
      <p>BUFFER<br>
        The padding (in pixels) for each label. This is used to enhance 
readability.
        A BUFFER of 4 pixels mean that no label will be drawn within four 
pixels
        of each other. Again, change to see how it works.<br>
      </p>
      <hr align="center" width="300">
      <p>You can also create labels separate from a POLYGON layer. You do 
this
        with the ANNOTATION data type. Have a look at the file 
"example1-4a.map"
        to see how you'd implement this kind of labeling. You will notice 
that
        the CLASS object within the "label" layer has a COLOR 
parameter
        value of "-1 -1 -1". The negative number tells MapServer 
to
        give this CLASS a transparent color (the label IDs don't show up). 
Once
        again, play with the values to understand how it affects the 
map.</p>
      <hr>
      <p class="Small" align="center"><a href="example1-3.html">Back to 
Example
        1.3</a> | <a href="section1.html">Back to the Section 1</a> | <a 
href="sections.html">Back to the Sections Page</a>
                | <a href="example1-5.html">Proceed to Example 1.5</a></p>
      </td>
</tr>
</table>
</body>
</html>

image tag as obtained from 'view source':
<img border="1" src="/cgi-bin/mapserv40?map=C:/Program Files/Apache 
Group/Apache2/htdocs/tutorial/example1-4.map&mode=map" />
--=_alternative 006849E887256E2E_=
Content-Type: text/html; charset="us-ascii"


<br><font size=2 face="sans-serif">I'm trying to work through Tutorial4.0 with MapServer 4.0 on Windows 2000.  I made the needed changes to the path information in the html and map files.  Everything works fine for Examples 1.1, 1.2, and 1.3, but from 1.4 on the image does not display.  What's different beginning with example 1.4?</font>
<br>
<br><font size=2 face="sans-serif">data directory:  C:\Program Files\Apache Group\Apache2\htdocs\tutorial\data</font>
<br><font size=2 face="sans-serif">mapserv40 located in:  C:\Program Files\Apache Group\Apache2\htdocs\cgi-bin</font>
<br>
<br><font size=2 face="sans-serif">Mapfile:</font>
<br><font size=2 face="sans-serif">MAP</font>
<br><font size=2 face="sans-serif">  IMAGETYPE      PNG</font>
<br><font size=2 face="sans-serif">  EXTENT         201621.496941 -294488.285333 1425518.020722 498254.511514</font>
<br><font size=2 face="sans-serif">  SIZE           400 300</font>
<br><font size=2 face="sans-serif">  SHAPEPATH      "data"</font>
<br><font size=2 face="sans-serif">  IMAGECOLOR     255 255 255</font>
<br>
<br><font size=2 face="sans-serif">  PROJECTION</font>
<br><font size=2 face="sans-serif">    "proj=laea"</font>
<br><font size=2 face="sans-serif">    "ellps=clrk66"</font>
<br><font size=2 face="sans-serif">    "lat_0=45"</font>
<br><font size=2 face="sans-serif">    "lon_0=-100"</font>
<br><font size=2 face="sans-serif">  #</font>
<br><font size=2 face="sans-serif">  # Alternatively, you can specify an EPSG code.</font>
<br><font size=2 face="sans-serif">  # "init=epsg:2163"</font>
<br><font size=2 face="sans-serif">  #</font>
<br><font size=2 face="sans-serif">  END</font>
<br>
<br><font size=2 face="sans-serif">  # Start of LAYER DEFINITIONS ---------------------------------------------</font>
<br><font size=2 face="sans-serif">  LAYER # States polygon layer begins here</font>
<br><font size=2 face="sans-serif">    NAME         states_poly</font>
<br><font size=2 face="sans-serif">    DATA         states_ugl</font>
<br><font size=2 face="sans-serif">    STATUS       DEFAULT</font>
<br><font size=2 face="sans-serif">    TYPE         POLYGON</font>
<br>
<br><font size=2 face="sans-serif">    PROJECTION</font>
<br><font size=2 face="sans-serif">      "init=epsg:4326"</font>
<br><font size=2 face="sans-serif">    END</font>
<br>
<br><font size=2 face="sans-serif">    CLASSITEM    "CLASS"</font>
<br><font size=2 face="sans-serif">    CLASS</font>
<br><font size=2 face="sans-serif">      EXPRESSION 'land'</font>
<br><font size=2 face="sans-serif">       COLOR      232 232 232</font>
<br><font size=2 face="sans-serif">    END</font>
<br><font size=2 face="sans-serif">    CLASS</font>
<br><font size=2 face="sans-serif">      EXPRESSION 'water'</font>
<br><font size=2 face="sans-serif">       COLOR      198 198 255</font>
<br><font size=2 face="sans-serif">    END</font>
<br><font size=2 face="sans-serif">  END # States polygon layer ends here</font>
<br>
<br><font size=2 face="sans-serif">  LAYER # States line layer begins here</font>
<br><font size=2 face="sans-serif">    NAME         states_line</font>
<br><font size=2 face="sans-serif">    DATA         states_ugl</font>
<br><font size=2 face="sans-serif">    STATUS       DEFAULT</font>
<br><font size=2 face="sans-serif">    TYPE         LINE</font>
<br>
<br><font size=2 face="sans-serif">    PROJECTION</font>
<br><font size=2 face="sans-serif">      "init=epsg:4326"</font>
<br><font size=2 face="sans-serif">    END</font>
<br>
<br><font size=2 face="sans-serif">    CLASSITEM    "CLASS"</font>
<br><font size=2 face="sans-serif">    CLASS</font>
<br><font size=2 face="sans-serif">      EXPRESSION 'land'</font>
<br><font size=2 face="sans-serif">      COLOR      32 32 32</font>
<br><font size=2 face="sans-serif">    END</font>
<br><font size=2 face="sans-serif">  END # States line layer ends here</font>
<br><font size=2 face="sans-serif">  # End of LAYER DEFINITIONS -------------------------------</font>
<br><font size=2 face="sans-serif">END # end of map file</font>
<br>
<br><font size=2 face="sans-serif">html:</font>
<br><font size=2 face="sans-serif"><html></font>
<br><font size=2 face="sans-serif"><head></font>
<br><font size=2 face="sans-serif"><title>MapServer 4.0 Tutorial</title></font>
<br><font size=2 face="sans-serif"><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"></font>
<br><font size=2 face="sans-serif"><link type="text/css" rel="stylesheet" href="ms35.css" /></font>
<br><font size=2 face="sans-serif"></head></font>
<br>
<br><font size=2 face="sans-serif"><body bgcolor="#FFFFFF" text="#000000"></font>
<br><font size=2 face="sans-serif"><table align="center" width="600" border="0"></font>
<br><font size=2 face="sans-serif"><tr></font>
<br><font size=2 face="sans-serif"><td></font>
<br><font size=2 face="sans-serif"><h3 align="center">Example 1.4: Labeling the Map</h3></font>
<br><font size=2 face="sans-serif">      <div align="center"><img border="1" src="/cgi-bin/mapserv40?map=C:/Program Files/Apache Group/Apache2/htdocs/tutorial/example1-4.map&mode=map" /></font>
<br><font size=2 face="sans-serif">      </div></font>
<br><font size=2 face="sans-serif">      <p align="left">We can also add labels to our map.</p></font>
<br><font size=2 face="sans-serif">      <hr></font>
<br><font size=2 face="sans-serif">      <p align="left">This is what the mapfile looks like:</p></font>
<br><font size=2 face="sans-serif">      <pre align="left">MAP</font>
<br><font size=2 face="sans-serif">  IMAGETYPE PNG</font>
<br><font size=2 face="sans-serif">  EXTENT 201621.496941 -294488.285333 1425518.020722 498254.511514</font>
<br><font size=2 face="sans-serif">  SIZE 400 300</font>
<br><font size=2 face="sans-serif">  SHAPEPATH &quot;data&quot;</font>
<br><font size=2 face="sans-serif">  IMAGECOLOR 255 255 255</font>
<br><font size=2 face="sans-serif">  FONTSET &quot;fonts/fonts.list&quot;</font>
<br>
<br><font size=2 face="sans-serif">  PROJECTION</font>
<br><font size=2 face="sans-serif">    &quot;proj=laea&quot;</font>
<br><font size=2 face="sans-serif">    &quot;ellps=clrk66&quot;</font>
<br><font size=2 face="sans-serif">    &quot;lat_0=45&quot;</font>
<br><font size=2 face="sans-serif">    &quot;lon_0=-100&quot;</font>
<br><font size=2 face="sans-serif">  #</font>
<br><font size=2 face="sans-serif">  # Alternatively, you can specify an EPSG code.</font>
<br><font size=2 face="sans-serif">  # &quot;init=epsg:2163&quot;</font>
<br><font size=2 face="sans-serif">  #</font>
<br><font size=2 face="sans-serif">  END</font>
<br>
<br><font size=2 face="sans-serif">  # Start of LAYER DEFINITIONS ---------------------------------------------</font>
<br><font size=2 face="sans-serif">  LAYER # States polygon layer begins here</font>
<br><font size=2 face="sans-serif">    NAME states_poly</font>
<br><font size=2 face="sans-serif">    DATA states_ugl</font>
<br><font size=2 face="sans-serif">    STATUS DEFAULT</font>
<br><font size=2 face="sans-serif">    TYPE POLYGON</font>
<br>
<br><font size=2 face="sans-serif">    PROJECTION</font>
<br><font size=2 face="sans-serif">      &quot;init=epsg:4326&quot;</font>
<br><font size=2 face="sans-serif">    END</font>
<br>
<br><font size=2 face="sans-serif">    CLASSITEM &quot;CLASS&quot;</font>
<br><font size=2 face="sans-serif">    LABELITEM &quot;STATE&quot;</font>
<br><font size=2 face="sans-serif">    CLASS</font>
<br><font size=2 face="sans-serif">      EXPRESSION 'land'</font>
<br><font size=2 face="sans-serif">      COLOR 232 232 232</font>
<br><font size=2 face="sans-serif">      LABEL</font>
<br><font size=2 face="sans-serif">        COLOR 132 31 31</font>
<br><font size=2 face="sans-serif">        SHADOWCOLOR 218 218 218</font>
<br><font size=2 face="sans-serif">        SHADOWSIZE 2 2</font>
<br><font size=2 face="sans-serif">        TYPE TRUETYPE</font>
<br><font size=2 face="sans-serif">        FONT arial-bold</font>
<br><font size=2 face="sans-serif">        SIZE 12</font>
<br><font size=2 face="sans-serif">        ANTIALIAS TRUE</font>
<br><font size=2 face="sans-serif">        POSITION CL</font>
<br><font size=2 face="sans-serif">        PARTIALS FALSE</font>
<br><font size=2 face="sans-serif">        MINDISTANCE 300</font>
<br><font size=2 face="sans-serif">        BUFFER 4</font>
<br><font size=2 face="sans-serif">      END # end of label</font>
<br><font size=2 face="sans-serif">    END</font>
<br><font size=2 face="sans-serif">  END # States polygon layer ends here</font>
<br>
<br><font size=2 face="sans-serif">  LAYER # States line layer begins here</font>
<br><font size=2 face="sans-serif">    NAME states_line</font>
<br><font size=2 face="sans-serif">    DATA states_ugl</font>
<br><font size=2 face="sans-serif">    STATUS DEFAULT</font>
<br><font size=2 face="sans-serif">    TYPE LINE</font>
<br>
<br><font size=2 face="sans-serif">    PROJECTION</font>
<br><font size=2 face="sans-serif">      &quot;init=epsg:4326&quot;</font>
<br><font size=2 face="sans-serif">    END</font>
<br>
<br><font size=2 face="sans-serif">    CLASSITEM &quot;CLASS&quot;</font>
<br><font size=2 face="sans-serif">    CLASS</font>
<br><font size=2 face="sans-serif">      EXPRESSION 'land'</font>
<br><font size=2 face="sans-serif">      COLOR 64 64 64</font>
<br><font size=2 face="sans-serif">    END</font>
<br><font size=2 face="sans-serif">  END # States line layer ends here</font>
<br><font size=2 face="sans-serif">  # End of LAYER DEFINITIONS -------------------------------</font>
<br><font size=2 face="sans-serif">END # end of map file</pre></font>
<br><font size=2 face="sans-serif">      <hr align="center" width="300"></font>
<br><font size=2 face="sans-serif">      <p>Here we introduce a few more parameters along with the LABEL object:</p></font>
<br><font size=2 face="sans-serif">      <p>FONTSET<br></font>
<br><font size=2 face="sans-serif">        Here we specify the full path to our truetype fonts list (or font set)</font>
<br><font size=2 face="sans-serif">        file. This file lists each of the available fonts. See the file itself</font>
<br><font size=2 face="sans-serif">        and the <a href="http://mapserver.gis.umn.edu/doc40/fontset.html">MapServer</font>
<br><font size=2 face="sans-serif">        fonset documentation</a> for more info. FONTSET is a parameter of the</font>
<br><font size=2 face="sans-serif">        MAP object.</p></font>
<br><font size=2 face="sans-serif">      <p>LABELITEM<br></font>
<br><font size=2 face="sans-serif">        This specifies which data attribute to use for labeling, in this case</font>
<br><font size=2 face="sans-serif">        &quot;STATE&quot;. LABELITEM is a parameter of the LAYER object.</p></font>
<br><font size=2 face="sans-serif">      <p>LABEL<br></font>
<br><font size=2 face="sans-serif">        Marks the beginning of the LABEL object. The label object can be used</font>
<br><font size=2 face="sans-serif">        under other objects (i.e. the SCALEBAR object).</p></font>
<br><font size=2 face="sans-serif">      <p> COLOR<br></font>
<br><font size=2 face="sans-serif">        Within the LABEL object, COLOR specifies the color of the label text.</p></font>
<br><font size=2 face="sans-serif">      <p>SHADOWCOLOR<br></font>
<br><font size=2 face="sans-serif">        This specifies the shadow color of the label text.</p></font>
<br><font size=2 face="sans-serif">      <p>SHADOWSIZE<br></font>
<br><font size=2 face="sans-serif">        Specifies the shadow size. The value corresponds to the X and the Y shifts</font>
<br><font size=2 face="sans-serif">        in pixels. So, &quot;2 2&quot; means two pixels wide by two pixels high.</p></font>
<br><font size=2 face="sans-serif">      <p>TYPE<br></font>
<br><font size=2 face="sans-serif">        Within the LABEL object, TYPE specifies what type of font to use. We have</font>
<br><font size=2 face="sans-serif">        the choice of TRUETYPE or BITMAP (the built-in fonts). We choose TRUETYPE.</p></font>
<br><font size=2 face="sans-serif">      <p>FONT<br></font>
<br><font size=2 face="sans-serif">        If you specify TYPE as TRUETYPE, you need to specify what font to use.</font>
<br><font size=2 face="sans-serif">        The value here is the &quot;alias&quot; in the font list file.</p></font>
<br><font size=2 face="sans-serif">      <p>SIZE<br></font>
<br><font size=2 face="sans-serif">        If using truetype fonts, the value is size in pixels. If bitmap, you can</font>
<br><font size=2 face="sans-serif">        say something like &quot;small&quot; or &quot;large&quot;.</p></font>
<br><font size=2 face="sans-serif">      <p>ANTIALIAS<br></font>
<br><font size=2 face="sans-serif">        This turns truetype antialiasing on or off. Remember the value isn't on</font>
<br><font size=2 face="sans-serif">        or off but TRUE or FALSE.</p></font>
<br><font size=2 face="sans-serif">      <p>POSITION<br></font>
<br><font size=2 face="sans-serif">        Where to position the label text in relation to the label points. The</font>
<br><font size=2 face="sans-serif">        value is a combination of vertical and horizontal positions. You have</font>
<br><font size=2 face="sans-serif">        the following choices for vertical alignment: C for center, U for upper,</font>
<br><font size=2 face="sans-serif">        and L for lower. For horizontal alignment you have the following choices:</font>
<br><font size=2 face="sans-serif">        C for center, L for left, and R for right. So, to align the label text</font>
<br><font size=2 face="sans-serif">        to the center of label ID you'd use the value &quot;CC&quot; (center-center).</font>
<br><font size=2 face="sans-serif">        Or if you'd like it to be on the lower left of the ID, you'd use LL. Another</font>
<br><font size=2 face="sans-serif">        way is to let MapServer decide the best position for your labels. For</font>
<br><font size=2 face="sans-serif">        this you would use the value &quot;AUTO&quot;.</p></font>
<br><font size=2 face="sans-serif">      <p>PARTIALS<br></font>
<br><font size=2 face="sans-serif">        Tells MapServer whether to generate incomplete label texts or not. The</font>
<br><font size=2 face="sans-serif">        default here is not to generate fragments of a label text. The value is</font>
<br><font size=2 face="sans-serif">        either TRUE or FALSE.</p></font>
<br><font size=2 face="sans-serif">      <p>MINDISTANCE<br></font>
<br><font size=2 face="sans-serif">        This is the minimum distance in pixels between duplicate labels. See what</font>
<br><font size=2 face="sans-serif">        happens if you increase or decrease this value.</p></font>
<br><font size=2 face="sans-serif">      <p>BUFFER<br></font>
<br><font size=2 face="sans-serif">        The padding (in pixels) for each label. This is used to enhance readability.</font>
<br><font size=2 face="sans-serif">        A BUFFER of 4 pixels mean that no label will be drawn within four pixels</font>
<br><font size=2 face="sans-serif">        of each other. Again, change to see how it works.<br></font>
<br><font size=2 face="sans-serif">      </p></font>
<br><font size=2 face="sans-serif">      <hr align="center" width="300"></font>
<br><font size=2 face="sans-serif">      <p>You can also create labels separate from a POLYGON layer. You do this</font>
<br><font size=2 face="sans-serif">        with the ANNOTATION data type. Have a look at the file &quot;example1-4a.map&quot;</font>
<br><font size=2 face="sans-serif">        to see how you'd implement this kind of labeling. You will notice that</font>
<br><font size=2 face="sans-serif">        the CLASS object within the &quot;label&quot; layer has a COLOR parameter</font>
<br><font size=2 face="sans-serif">        value of &quot;-1 -1 -1&quot;. The negative number tells MapServer to</font>
<br><font size=2 face="sans-serif">        give this CLASS a transparent color (the label IDs don't show up). Once</font>
<br><font size=2 face="sans-serif">        again, play with the values to understand how it affects the map.</p></font>
<br><font size=2 face="sans-serif">      <hr></font>
<br><font size=2 face="sans-serif">      <p class="Small" align="center"><a href="example1-3.html">Back to Example</font>
<br><font size=2 face="sans-serif">        1.3</a> | <a href="section1.html">Back to the Section 1</a> | <a href="sections.html">Back to the Sections Page</a></font>
<br><font size=2 face="sans-serif">                | <a href="example1-5.html">Proceed to Example 1.5</a></p></font>
<br><font size=2 face="sans-serif">      </td></font>
<br><font size=2 face="sans-serif"></tr></font>
<br><font size=2 face="sans-serif"></table></font>
<br><font size=2 face="sans-serif"></body></font>
<br><font size=2 face="sans-serif"></html></font>
<br>
<br><font size=2 face="sans-serif">image tag as obtained from 'view source':</font>
<br><font size=2 face="sans-serif"><img border="1" src="/cgi-bin/mapserv40?map=C:/Program Files/Apache Group/Apache2/htdocs/tutorial/example1-4.map&mode=map" /></font>
--=_alternative 006849E887256E2E_=--



More information about the MapServer-users mailing list