[Mapserver-users] Re: MapServer 4.0 Tutorial problems

Pericles Nacionales nacional at cbs.umn.edu
Tue Feb 3 14:06:22 PST 2004


Dave, Carol, other tutorial users,

Sorry for the long message but please do read on...

> > 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?
>
> Carol,
>
> This sounds a lot like the problem I encountered with example 1.4.  To
> check, try commenting out these three lines from the LABEL object in the
> 'land' CLASS of the 'states_poly' LAYER:
>
>       TYPE TRUETYPE
>       FONT arial-bold
>       SIZE 12
>
> If commenting those lines out makes it work, see below for my
> solution/workaround.  Maybe it will help you, too.
>

If you're going to forgo TRUETYPE fonts, don't comment out TYPE and SIZE.
Instead, replace the TYPE line with "TYPE BITMAP" and the SIZE line with
"SIZE LARGE".  You will then have to comment out the other keywords
related to truetype font support (i.e., ANTIALIAS).


> > Hi there!  Can you have a look at your web server's error log and see if
> > there's anything pertinent to the TrueType error you're getting?  You
> > might also want to check the permissions on your fonts and fonts
> > directory--make sure the web server account have access to the
> > directory/read access to files.
>
> Perry,
>
> First, thanks for the great tutorial.  It has proved very useful and
> educational already, in spite of the various problems I've encountered
> with it.
>
> All I see in the access log is a status code 500, but I'm on a hosting
> service, so I don't seem to have access to the error logs.  Permissions
> and such are ok, as I learned when I accidentally got TrueType to work in
> another map file I was working on.  Through a long process of trial and
> error, I finally figured out that this is what made it work:
>
>   OUTPUTFORMAT
>     DRIVER "GDAL/GTIFF"
>   END
>
> Adding those three lines to the MAP object in example 1.4 causes TrueType
> fonts to work perfectly.  I have no idea how or why, or whether this would
> be called a MapServer bug or a tutorial bug.  By my understanding, those
> lines shouldn't even matter, since I'm still using "IMAGETYPE PNG".  But
> somehow 'DRIVER "GDAL/GTIFF"' makes it work, and using 'DRIVER "GD/PNG"'
> instead doesn't work.

Interesting.  GDAL has nothing to do with this example.  If you are in
Windows and are using one of the binary packages from the MapServer site,
it's possible that it has something to do with my binaries.

>
> A minor nitpick in the text of 1.4:  At the bottom of the page, it
> mentions "example1-4a.map" in reference to the ANNOTATION data type.  That
> file does not exist, though example1-5.map does use ANNOTATION.
>

Oops!  Sorry about that.  I'll have it fixed shortly.

> Now that I've gotten 1.4 to work, on to 1.5....
>
> First, I find that the same OUTPUTFORMAT hack is needed for 1.5.  No
> surprise there.  But that is not sufficient to get it to work for me.  I
> also need to replace "IMAGETYPE PNG24" with "IMAGETYPE PNG" and disable
> the "modis" layer.  Only then does it produce an image, though obviously
> without the raster layer displayed.
>
> Any guesses why PNG24 fails (with or without the raster layer) and the
> raster layer fails (with or without PNG24)?  I've tried using the idxa
> version of the image, but that doesn't work, either.
>

That's very odd indeed.  I've never encountered this problem even when
using Windows.  I'll have to go back and check again.

FYI: I just updated the binaries in the MapServer site.  I have added
Frank's fix to bug 504.  I don't think the fix has anything to do with it
(it's for tiled rasters).  However, the version is now at 4.0.1.  Also,
MapServer 3.6 is now at version 3.6.7.

Thanks for your help.
-Perry N.



> Thanks again,
> Dave
>
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>



More information about the MapServer-users mailing list