jQuery and Google Maps API V3 - Getting Started
I am just starting out on a project u开发者_Go百科sing jQuery and Google Maps API V3. I do NOT want to use a plugin. I want to start from scratch dropping addresses into jQuery and displaying a map. Eventually, I'll display a list of local properties on a complex map.
I will NOT be using the jQuery UI. I will NOT be using a jQuery plugin.
It there an easy tutorial that has all of the basic information that I would need to gain a good understanding?
Thanks!!!
Short answer is no, not that I have found. I was hoping for some neato way to tie these two technologies together but basically Google Maps stands on its own.
You could use jQuery to build surrounding elements like building a list of items to toggle but things like the map, adding markers, and adding click handlers are all provided by the Google Maps API.
Even the directions api returns a complete set of directions with html and clickable markers all with a line or two of code and a dom reference to inject the html into.
Your best bet is to forget about jQuery to start off and just dive in to the Google Maps v3 API Documentation. There are several samples that show you how to do all the must have features and if you're coming over from v2 then there is a lot that is included now for free (scroll wheel support and Street View for example).
- http://code.google.com/apis/maps/documentation/javascript/tutorial.html
After that you might want to display your own content from a database based on a location or update an info panel or some such and thats when you can dip into the jquery goodness.
Your question is very unclear. What exactly do you want to do ?
Display location markers ?
If you just want to have a map with a bunch of markers you can use the exemples here : http://code.google.com/apis/maps/documentation/javascript/basics.html
and use a JSON array to store your locations and dynamically display them as markers on your map ?
精彩评论