[mapserver-users] Changing IMAGECOLOR with PHP MapScript
Chip.Hankley at GASAI.Com
Thu Sep 27 17:48:56 EDT 2001
I tried this
($map is passed)
$bgcolor = $map->addcolor(238,238,238);
...and now I get the following error:
Fatal error: Property 'imagecolor' does not exist in this object. in
c:\inetpub\wwwroot\seating\seating.php on line 567
I think you have to add a colour first before you try to set its
property (see the MapObject Class and its members in
such as the following:
$color = $map->addcolor(0,0,0);
DM Solutions Group Inc.
From: Jeff McKenna [mailto:mckenna at dmsolutions.ca]
Sent: Thursday, September 27, 2001 3:33 PM
To: Hankley, Chip
Subject: Re: [mapserver-users] Changing IMAGECOLOR with PHP MapScript
"Hankley, Chip" wrote:
> Can someone please show me how to change the background color of my map
> PHP MapScript.
> This is the basics of what I've tried so far...
> $map = ms_newMapObj("GB01.map");
> $map->set("imagecolor", 0 0 0);
> $map->set("imagecolor", setRGB(0, 0, 0));
> ...neither seem to be working.
> Chip Hankley
More information about the mapserver-users