<html>
<head>
</head>
<body>
Steve,<br>
<br>
sounds great to me, but:<br>
<br>
a) can I do this with mapserver 3.4 ?<br>
<br>
b) where to put/send the variable codelist ? Append it in the URL? Like e.g.:
<a class="moz-txt-link-freetext" href="http://path/to/mapserver.phtml?codelist=AT">http://path/to/mapserver.phtml?codelist=AT</a>|DE|IT ? Doesn't work like this!<br>
<br>
The mapfile looks like this (it work, when I sustitute %codelist% with e.g.
AT|DE|IT - they turn red):<br>
...<br>
...<br>
...<br>
LAYER<br>
NAME nut3<br>
DESCRIPTION "nut3"<br>
CLASSITEM "Nurgcd"<br>
# LABELITEM "Arrgcdl0"<br>
QUERYITEM "Nurgcd"<br>
TYPE POLYGON<br>
STATUS ON<br>
<br>
DATA nut3 <br>
CLASS<br>
EXPRESSION /%codelist%/<br>
NAME "0"<br>
COLOR 255 0 0<br>
END<br>
CLASS<br>
EXPRESSION /DE|IT|LI/<br>
NAME "1"<br>
COLOR 188 137 137<br>
END<br>
CLASS<br>
EXPRESSION /AT|FR|BE/<br>
NAME "2"<br>
COLOR 188 182 137<br>
END<br>
CLASS<br>
EXPRESSION /DK|NL/<br>
NAME "3"<br>
COLOR 141 188 137<br>
END<br>
CLASS<br>
EXPRESSION /CH|LU|SI/<br>
NAME "4"<br>
COLOR 137 175 188<br>
END<br>
CLASS<br>
EXPRESSION /EUCON|EULAK/<br>
NAME "4"<br>
COLOR 210 210 210<br>
END<br>
<br>
HEADER "Nurgcd NURGNM Link"<br>
TOLERANCE 1<br>
QUERYITEM "NURGNM"<br>
QUERY<br>
EXPRESSION /./<br>
TEMPLATE "ttt"<br>
END <br>
END<br>
<br>
--------------------<br>
mfg<br>
ALEX<br>
<br>
<br>
<br>
Stephen Lime wrote:<br>
<blockquote type="cite" cite="mid:sbb210b1.052@co5.dnr.state.mn.us">
<pre wrap="">Seems to me the easiest way to do this is to turn the results of the SQL query into a either an attribute query or a class expression that hilites the right polys. This assumes you have a primary key between the 2 systems, a county code or something. I'd recommend the class expression option since it's the most straight forward. 3.5 has a couple of nice features that make doing this sort of thing pretty easy. Basically you set up a map with 2 parts, layer descriptions that compose the background of the map and a single layer to use in displaying the right countries. That single layer is what you manipulate the class expression for. Set the status to OFF for that layer and set up a class like:<br><br>CLASS<br> EXPRESSION /%codelist%/<br> ...<br>END<br><br>Then in your other app you'd create a variable that cats all the country codes together (i.e. id1|id2|id3) called codelist. MapServer CGI will substitute the value of codelist for %codelist% and there you hav
e it, a dynamic expression. Be sure to turn the layer on.<br><br>No need to go to MapScript on this one...<br><br>Steve <br><br>Stephen Lime<br>Data & Applications Manager<br><br>Minnesota DNR<br>500 Lafayette Road<br>St. Paul, MN 55155<br>651-297-2937<br></pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">Alexander Pucher <a class="moz-txt-link-rfc2396E" href="mailto:pucher@atlas.gis.univie.ac.at"><pucher@atlas.gis.univie.ac.at></a> 09/26/01 07:11 AM >>><br></pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap=""><!---->Hello,<br><br>I want to explain my question with a little example.<br><br>Let's presume, I have a map of Europe with all the european countries <br>included. In addition to that, I have statistical data about the various <br>countries - like population, area etc. - stored in a database system - <br>say MySQL. I make a SQL query, showing me the 3 countries with the <br>highest poulation figures (e.g. Germany, France, UK). The system gives <br>me a button saying "Show in Mapserver". What I want to see is the map of <br>Europe with the three countries hilited.<br><br>I'm quite sure that this has to be done with a newLayerObj, that is <br>simply put onto the "standard" layers. Can anybody give me some more <br>detailed information about this. Any suggestions, code snippets, links <br>or previously posted messages to mapserver-users-group would be great.<br><br>mfg<br>ALEX <br><br></pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="$mailwrapcol">--
________________________________________________________
Institut fuer Geographie und Regionalforschung
Universität Wien
Kartografie und Geoinformation
Departement of Geography and Regional Research
University of Vienna
Cartographie and GIS
Universitaetstr. 7, A-1010 Wien, AUSTRIA
Tel: (+43 1) 4277 48644
Fax: (+43 1) 4277 48649
E-mail: <a class="moz-txt-link-abbreviated" href="mailto:pucher@atlas.gis.univie.ac.at">pucher@atlas.gis.univie.ac.at</a>
FTP: <a class="moz-txt-link-freetext" href="ftp://ftp.gis.univie.ac.at">ftp://ftp.gis.univie.ac.at</a>
WWW: <a class="moz-txt-link-freetext" href="http://www.gis.univie.ac.at/karto">http://www.gis.univie.ac.at/karto</a>
________________________________________________________
"The toughest fight, was with my wife." -- Muhammad Ali
</pre>
<br>
</body>
</html>