13 June 2007

Google Maps API and AJAX LocalSearch Control

Google Map API and AJAX Search API get closer ...

the one liner that makes it happen
map.addControl(new google.maps.LocalSearch());

Update Please Note: Adsense is not Enabled yet but in the pipeline.

Note: Google will serve advertisements if you use this Local Search Control.

In addition to providing useful search results to users of your Google Maps API powered site, the Local Search Control for Google Maps is designed to help you make more money from your maps mashup. Search is a great opportunity to target relevant AdSense ads to users of your site. If you pass your AdSense ID into the constructor of your Local Search Control, then you will share in the revenue from clicks on the AdSense ad(s) generated by the Search Control. If you do not provide your AdSense ID, then ad(s) will still be served, but you will not receive revenue from those advertisements.

Embedded AJAX API Local Search Control in Google Map

(corrected url for the css)

Official Post

Google Map API response

more info and stay tuned on Adsense in Google Maps!:

Labels: , , , , ,


At Wednesday, June 13, 2007 5:43:00 am, Blogger Mark Lucovsky, Software Engineer said...

hey, you have a small bug...

@import url("http://www.google.com/uds/css/gmlocalsearch.css");

should be:

@import url("http://www.google.com/uds/solutions/localsearch/gmlocalsearch.css");

At Wednesday, June 13, 2007 8:42:00 am, Blogger Mapperz said...

Thanks Mark, the trouble with 'half a sleep' copying and pasting before sleep comes to light in the morning after a first cup of tea.

Thanks for the code correction.


At Thursday, June 14, 2007 5:10:00 pm, Blogger gpsmapper said...

So can this be done now (using your AdSense ID), or is it a future feature?

At Thursday, June 14, 2007 10:44:00 pm, Blogger Mapperz said...

It was in the javascript file

mapperz sources:

more info here

call it 'tinkering'

but more options and full documentation coming soon from the official source.


Post a Comment

<< Home