Reputation: 3511
I have a website where some users enter some data. Address is one of those data. I want to get html like this.
<iframe width="425" height="350" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="https://maps.google.com/?ie=UTF8&ll=37.0625,-95.677068&spn=51.708931,101.425781&t=m&z=4&output=embed"></iframe><br /><small><a href="https://maps.google.com/?ie=UTF8&ll=37.0625,-95.677068&spn=51.708931,101.425781&t=m&z=4&source=embed" style="color:#0000FF;text-align:left">View Larger Map</a></small>
I want to make some webrequest by entered address and then parse html and get html for embedding. Any better idea?
Upvotes: 0
Views: 743
Reputation: 3198
There is a JQuery solution o this,ie the user enters address in a text box and address loads up dynamically in a map.
$(document).ready(function(){
var map = $('#map').acts_as_map_container();
// params:
// container is required
// suggestion is the element which will contain the suggested address, default to #suggested
// delay is the delay time for requesting google map api, default to 500ms
var address = $('#address').acts_as_address({
container: map,
suggestion: '#suggestion',
delay : 500
});
})
Upvotes: 1