freakstyle

~~~ Really only another WordPress ? ~~~

php google maps v3

The third version of googlemaps api let You do many useful things You should need to do with a map, thoose api is medium huge, and some things are not so often used, on the other hand some stuff are more frequently used and speed up the usage without writing a single javascript line could be a good idea.

Having a php class that allows You to render a map and use a good subset of api v3 in few simple lines could be a good solution to achieve the result.

I came up with a clean, handy and useful class that render the map allowing the programmer to use many elements of the last Api in the easiest way. Moreover I added some extra functionalities like “flickr layer”. Take a look at the samples of usage of the class now and good mapping !!!

Here you can download the class, and here you`ll find many samples.

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

Categorised as: javascript, php


4 Comments

  1. Mark says:

    Wonderful class Frederico.
    Most instance I come across have a layout need to display the map (after user clicks on a link) in a popup window, div (after setting display or visible) or iframe.
    Have you made any efforts to providing samples for such a thing?

    • Federico says:

      Hi Mark,

      first of all thank You.

      If I didn’t misunderstood You mean something like this.

      I used jQuery (porting to any framework is trivial), and three really simple php file that uses a little variation of that sample.
      While popup or iframe are pretty trivial, I spent some more on loading the map on a div because I was trying to get content via ajax and then load sync the response in the div, but it doesn’t work, so I included a php in the hidden div, and at click I bind show of div and initialize of the map.
      Hope it helps!

      Bye

  2. Mark says:

    Sweet! Yeah that helps me a lot. Thank you so much for the extra effort.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>