[Mapserver-users] simple php/mapscript question
Murat Isik
muratisik at megatek.com.tr
Tue Feb 17 05:08:16 PST 2004
This is a multi-part message in MIME format.
------=_NextPart_000_03A3_01C3F567.DF0B4440
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hello,
I am trying to build a php site with mapscript. So far it goes good but =
in order to have variable SIZE or COLOR settings for different =
situations I have to create multiple layers with almost same settings =
but with different names. For example this is one of them:
LAYER
NAME roads6
TYPE line
STATUS OFF
DATA ROADS_polyline
LABELCACHE ON
LABELITEM 'Name'
CLASS
NAME 'Roads'
COLOR 55 60 223
LABEL
TYPE truetype
# FORCE true
FONT arial
COLOR 0 0 0
ANGLE AUTO
POSITION AUTO
MINSIZE 2
SIZE 6
END
END
END
Within php I know how to make a layer ON:
$layer =3D $map->getLayerByName(roads6);
$layer->set("status", MS_ON);
Just like that, what are the ways to set the both COLORs and SIZE? I =
wish the mapserver site had more examples :(
Have a nice day.
Murat Isik
------=_NextPart_000_03A3_01C3F567.DF0B4440
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-1" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.3813.800" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV> </DIV>
<DIV><FONT size=3D2>Hello,</FONT></DIV>
<DIV> </DIV>
<DIV><FONT size=3D2>I am trying to build a php site with mapscript. So =
far it goes=20
good but in order to have variable SIZE or COLOR settings for different=20
situations I have to create multiple layers with almost same settings =
but with=20
different names. For example this is one of them:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT size=3D2>LAYER<BR> NAME roads6<BR> TYPE =
line<BR> =20
STATUS OFF<BR> DATA ROADS_polyline<BR> LABELCACHE =
ON<BR> =20
LABELITEM 'Name'<BR> CLASS<BR> NAME =
'Roads'<BR> =20
<STRONG>COLOR 55 60 223</STRONG><BR> =20
LABEL<BR> TYPE=20
truetype<BR># FORCE=20
true<BR> FONT=20
arial<BR> <STRONG>COLOR 0 0=20
0</STRONG><BR> ANGLE=20
AUTO<BR> POSITION=20
AUTO<BR> MINSIZE=20
2<BR> <STRONG>SIZE =
6</STRONG><BR> =20
END<BR> END<BR>END<BR></FONT></DIV>
<DIV><FONT size=3D2></FONT> </DIV>
<DIV><FONT size=3D2>Within php I know how to make a layer =
ON:</FONT></DIV>
<DIV><FONT size=3D2></FONT> </DIV>
<DIV><FONT size=3D2>$layer =3D=20
$map->getLayerByName(roads6);<BR>$layer->set("status",=20
MS_ON);</FONT></DIV>
<DIV><FONT size=3D2></FONT> </DIV>
<DIV><FONT size=3D2>Just like that, what are the ways to set the both =
COLORs and=20
SIZE? I wish the mapserver site had more examples :(</FONT></DIV>
<DIV><FONT size=3D2></FONT> </DIV>
<DIV><FONT size=3D2>Have a nice day.</FONT></DIV>
<DIV><FONT size=3D2></FONT> </DIV>
<DIV><FONT size=3D2>Murat Isik</FONT></DIV>
<DIV><FONT size=3D2> </DIV></FONT></BODY></HTML>
------=_NextPart_000_03A3_01C3F567.DF0B4440--
More information about the MapServer-users
mailing list