Erika, I have some cf examples of the ajax calls needed for both googlemaps and yahoomaps.
I will try to find them after work tonight. If I forget, can you send me a reminder? (Not the best code, but working, and shows how) On Fri, Feb 27, 2009 at 12:58 PM, Erika L. Walker <[email protected]>wrote: > > Thanks Nathan - I posted the sample code for looking up the address... ( > http://coldfusion.pastebin.com/m3e9365a1) but it displays the map for the > "onSubmit" action of the form. > > I wont have a form. I'm being clueless as to how to trigger the JS function > to do the geocode lookup and display my database supplied address. > > > 1. function showAddress(address) { > 2. if (geocoder) { > 3. geocoder.getLatLng( > 4. address, > 5. function(point) { > 6. if (!point) { > 7. alert(address + " not found"); > 8. } else { > 9. map.setCenter(point, 13); > 10. var marker = new GMarker(point); > 11. map.addOverlay(marker); > 12. marker.openInfoWindowHtml(address); > 13. } > 14. } > 15. ); > 16. } > > > > 1. <form action="#" onsubmit="showAddress(this.address.value); return > false"> > 2. <p> > 3. <input type="text" size="60" name="address" value="1600 > Amphitheatre Pky, Mountain View, CA" /> > 4. <input type="submit" value="Go!" /> > 5. </p> > 6. <div id="map_canvas" style="width: 500px; height: 300px"></div> > 7. </form> > > > > On Fri, Feb 27, 2009 at 12:42 PM, Nathan Blixt <[email protected]> wrote: > > > > > This is possible with their API. I can't look up too many examples right > > now, but I was playing around with it to list art galleries in our area: > > http://upartmap.bluepx.com > > > > I got most of the code from the API's demo section. > > > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/cf-community/message.cfm/messageid:290033 Subscription: http://www.houseoffusion.com/groups/cf-community/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.5
