Convert <address> tag to Google Maps embed automatically with jQueryOctober 4th, 2012 by Michael Jasper
Converting an <address> tag into a Google maps link is something I’ve written about in the past, but user “Moose” was wondering if you can do the same thing, but transform it into an embedded map. Quick answer: Yes!
Using jQuery, we search the document for <address> tags, create some HTML to embed the map with the current address inserted in it, then write that HTML out into the current spot.
var embed ="<iframe width='425' height='350' frameborder='0' scrolling='no' marginheight='0' marginwidth='0' src='https://maps.google.com/maps?&q="+ encodeURIComponent( $(this).text() ) +"&output=embed'></iframe>";