<div>Hi Stephen</div>
<div> </div>
<div> thanks for the tip... I read the example and implements it with my data. </div>
<div> </div>
<div>
<div id="result_box" dir="ltr" style="TEXT-ALIGN: left">Now my problem is :how to rescue the data for instructions,distance,time etc? ..</div>
<div dir="ltr" style="TEXT-ALIGN: left">
<div id="result_box" dir="ltr" style="TEXT-ALIGN: left">how can I know whether to turn right or left?</div></div><br>RG.</div>
<div class="gmail_quote">2009/1/20 Stephen Woodbridge <span dir="ltr"><<a href="mailto:woodbri@swoodbridge.com">woodbri@swoodbridge.com</a>></span><br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Valeria,<br><br>You should really look at the example provided with:<br><a href="http://pgrouting.postlbs.org/wiki/WorkshopFOSS4G2007" target="_blank">http://pgrouting.postlbs.org/wiki/WorkshopFOSS4G2007</a><br>
<br>This is what I started with and then made my own modifications. The above workshop should walk you through how to setup a pgRouting without my additional hacks which will only confuse you at the moment.<br><br>My dd_routing.php is a modified version of ax_routing.php that is included in the tutorial tarball.<br>
<br>You might also want to read some of these pages if you have not already:<br><a href="http://www.google.com/search?hl=en&q=pgRouting&btnG=Google+Search" target="_blank">http://www.google.com/search?hl=en&q=pgRouting&btnG=Google+Search</a><br>
<br>Best regards,<br> -Steve W<br><br>Valeria Muņoz wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div class="Ih2E3d">hi Stephen.. thank for the tips...<br>I have reviewed the code but can only see the dd.html. can you send me the dd_routing.php? .<br> please<br><br>thanks for everything<br></div>2009/1/19 Stephen Woodbridge <<a href="mailto:woodbri@swoodbridge.com" target="_blank">woodbri@swoodbridge.com</a> <mailto:<a href="mailto:woodbri@swoodbridge.com" target="_blank">woodbri@swoodbridge.com</a>>>
<div class="Ih2E3d"><br><br> Valeria Muņoz wrote:<br><br> frank<br> thanks for the tips. I use prRouting and create the table<br> dijsktra_result. Now how can I implement with my mapfile? , how<br>
deliver the data .. have some sample code?<br><br> thanks for your help.<br><br> 2009/1/19 Frank Warmerdam <<a href="mailto:warmerdam@pobox.com" target="_blank">warmerdam@pobox.com</a><br></div> <mailto:<a href="mailto:warmerdam@pobox.com" target="_blank">warmerdam@pobox.com</a>> <mailto:<a href="mailto:warmerdam@pobox.com" target="_blank">warmerdam@pobox.com</a>
<div>
<div></div>
<div class="Wj3C7c"><br> <mailto:<a href="mailto:warmerdam@pobox.com" target="_blank">warmerdam@pobox.com</a>>>><br><br><br> Valeria Muņoz wrote:<br><br> Hi<br> I would like to implement the service "optimum path<br>
between 2<br> points," can someone help me to be able to implement it?. The<br> general idea is that a user picks a point A and point B and a<br> display on the map the best route to get from point A to B.<br>
<br><br> Valeria,<br><br> MapServer itself does not do route calculation. You might<br> find some<br> useful pointers on this page:<br><br> <a href="http://wiki.osgeo.org/wiki/OpenRouter" target="_blank">http://wiki.osgeo.org/wiki/OpenRouter</a><br>
<br> I think the pgRouting (built on postgres/postgis) is the best<br> bet for<br> integration with MapServer.<br><br><br> So you have various options depending on the client software you are<br>
using. So here are some ideas for you:<br><br> 1) put the route into a results table with a unique id, and pass the<br> unique id back to the client where it can then request the route<br> image via a mapserver mapfile the connects to the postgis database<br>
and requests the layer be drawn with the unique id to select the<br> appropriate route.<br><br> 2) make an ajax request to generate the route and return the<br> polyline as an xml or json object back to the client. The client<br>
then parses the result document and displays the route over the map.<br><br> 3) if you use OpenLayers for the client then you can use it to help<br> you do 1) as an image, or 1) as a wfs layer, or 2) as a vector layer.<br>
<br> You can look at the source for my demo page<br> <a href="http://imaptools.com/leaddog/routing/dd.html" target="_blank">http://imaptools.com/leaddog/routing/dd.html</a> which does this with a<br> modified version of pgRouting (pgRouting does not return<br>
turn-by-turn directions), but you should be able to modify my code<br> to work with pgRouting. I wrote a simple php script to proxy the<br> route request into postgres and to format the results back to the<br> client.<br>
<br> Look this over and see how far you can get with this. If you get<br> stuck, ask and I'm sure we can get you moving in the right direction.<br><br><br></div></div></blockquote><br></blockquote></div><br>