On Oct 6, 2011, at 5:11 AM, Robert Buckley wrote:
> If I have multiple charts which use mulitple queries, am I able to put them
> in one php script or do I need a seperate script for each query?
>
> Please excuse me if this should not be posted here...but I consider this more
> of a postgis/webmapping question as a sencha/extjs question.
It's really a client side question, but I'll try explain. If you currently
get data for your charts using
chart1.php
chart2.php
...
and you are looking to consolidate and share code you can create one script
with all the same common code that takes an argument to change the sql query
for each chart. You'd then call it with
chart.php?type=1
chart.php?type=2
In your php you'd look at the type and modify the sql string used in the query.
If the results/columns differ from the queries you'll need further logic to
handle them differently by type.
hth
charles
_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users