[OpenLayers-Users] display php& postgresql queries in openlayers via Geojson format

javad sadidi jsadidi at gmail.com
Fri Aug 12 07:42:13 EDT 2011


I am using openstreet maps OSM as the background for my projects and I am
doing pgrouting to find the best route. it works fine.my database for
routing is inside the postgresql .
now I have added a field in my table in postgresql , this field is the
status of the streets , I mean some records of this field are CLOSE and the
rest are OPEN.
I want to show the CLOSE records from the Status field in the browser with
Geojson format. for sure I have to do a query like , select * from mytable
WHERE status='CLOSE;
I use php for server side dealing . my database projection is in geographic
4326 and the OSM streets in the browser is in mercator 900913.
how can I display the result of the query as a line vector layer in the
browser ?
I know that I have ti cerate a layer in openlayer and write php codes to do
the query , but it doesnt work. who can help me in more details or show an
example exception pgrouting workshop 2010.
sinecerly
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20110812/ec28cb9c/attachment.html


More information about the Users mailing list