[Mapserver-users] Label outlinecolor in PHP MapScript?
Dylan Keon
keon at nacse.org
Mon Jan 5 07:45:32 PST 2004
Anyone know the correct syntax for setting a label outlinecolor in PHP
MapScript? I'm using MS 4.0.1.
The following code gives me a "Call to a member function on a
non-object" error on line 84.
Thanks,
Dylan
80 if($map->scale <= 140000) {
81 $quad_layer = $map->getLayerByName('quad_index_24k');
82 $quad_class = $quad_layer->getClass(0);
83 $quad_style = ms_newStyleObj($quad_class);
84 $quad_style->{label}->outlinecolor->setRGB(255,255,255);
85 }
LAYER
NAME quad_index_24k
TYPE POLYGON
DATA quad24k
STATUS ON
MAXSCALE 2400000
LABELMAXSCALE 600000
LABELMINSCALE 20000
TEMPLATE "null"
CLASS
OUTLINECOLOR 0 25 140
COLOR -1 -1 -1
TEXT ([MAP_NAME] [OHIOCODE])
LABEL
WRAP " "
POSITION CC
SIZE SMALL
FORCE TRUE
MINFEATURESIZE 35
#OUTLINECOLOR 255 255 255
END
END
END
More information about the MapServer-users
mailing list