[Mapserver-users] More MapScript 3.7 problems

Lars V. Nielsen LVN at gispro.dk
Sun Feb 9 14:29:59 EST 2003


Hi Dylan,

There's only one expression that covers my situation here: Doh!

I _had_ read the migration document, but it completely slipped my mind when hazzling over PHP 4.3.0 and other issues (re: my other
recent post). Thanks for turning me in the right direction.

However, I still can't seem to get it to output anything but gif. It complains over $map->draw() (saying: Warning: MapServer Error
in msDrawMap(): Unable to initialize image. in c:\...\map.php on line 308). I've copy'n'paste'd the example in the OutputFormat
guide, only changing the IMAGETYPE setting to e.g. "jpeg".

I'm currently having to run MapScript 3.7 under PHP 4.2.3, and that might be the cause of the problem as well.

I'm sure it's something rather simple, but I can't see what it is right now (i.e. Sunday evening).

Best regards/Med venlig hilsen
Lars V. Nielsen
GisPro, Denmark
http://www.gispro.dk/
http://hjem.get2net.dk/lars-online/
WGS84: 10.20'40"E 55.20'20"N
----- Original Message -----
From: "Dylan Keon" <keon at nacse.org>
To: "Lars V. Nielsen" <LVN at gispro.dk>
Cc: "MAPSERVER-L" <mapserver-users at lists.gis.umn.edu>
Sent: Sunday, February 09, 2003 5:15 PM
Subject: Re: [Mapserver-users] More MapScript 3.7 problems


> Lars V. Nielsen wrote:
>  > Hi,
>  >
>  > It seems that recently released MapScript 3.7 (dev) ($Revision: 1.143
> $ $Date: 2003/02/04 15:39:43 $) only outputs interlaced GIF
>  > images regardless of using different settings in "saveImage" and
>  > "saveWebImage". I've tried outputting PNG and JPEG, and tried to
>  > turn off interlacing, but nothing changes in the output.
>
>
> MS 3.7 handles output images differently than previous versions.  In
> your mapfile you can declare several output format types with the
> OUTPUTFORMAT object, then use IMAGETYPE to identify the output format
> you want to use.  saveImage() and saveWebImage() look at the parameters
> declared in whichever outputformat is in use, and use those parameters
> to create the output image.  So, instead of using something like
> $img->saveImage($img_name,'MS_PNG',0,0,0); you can just use
> $img->saveImage();.
>
> See http://mapserver.gis.umn.edu/cgi-bin/wiki.pl?OutputFormat for
> detailed information about the OUTPUTFORMAT object.  See
> http://mapserver.gis.umn.edu/cgi-bin/wiki.pl?MigrationGuide for changes
> that you need to make when migrating to 3.7.
>
> --Dylan
>
> _______________________________________________
> 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