CGI Mapserver: php template?

Steve Lime steve.lime at DNR.STATE.MN.US
Mon Aug 16 14:29:08 PDT 2004


You'd do this using a URL template. Let's say you want to click on a
polygon, get its ID and
then generate a report out of MySQL. Well, MapServer will get you the
right ID and can pass
that along to another script (in PHP), but you'll have to right the PHP
script. Sounds like you
know that part. So, if you have a script called report.phtml you could
write a template like:

  TEMPLATE "http://yourserver.wisc.edu/report.phtml?id=[ID]"

You basically end up stringing queries together. Make sense?

Steve

>>> BONNER S KARGER <bskarger at STUDENTS.WISC.EDU> 8/16/2004 3:52:37 PM
>>>
Hello listers,

When using the CGI MapServer, is it possible to send query results to
multiple files? I'm trying to send CGI query results to two different
files, one .html and one .php. Can this be done? According to the
TEMPLATE documentation, it can take only 1 file, or a URI.

I'm trying to grab a query result (from a .dbf) and use php to send
that result to MySQL for a DB query.  I cannot use ODBC connection,
hence the use of php.

Any ideas?

Thanks

-------------------------------------
Bonner Karger
Soils Extension, UW-Madison
1525 Observatory Drive
Madison, WI 53706
bskarger at wisc.edu



More information about the MapServer-users mailing list