Follow all the steps in below tutorial and modify it to list your favorite parks and campgrounds.
This tutorial shows you how to display information from a MySQL database on a Google Map using the Maps JavaScript API.
https://developers.google.com/maps/documentation/javascript/mysql-to-maps
Modify the given solution so that PHP returns data not in XML but in JSON format (hint: use json_encode() function). Subsequently, in Creating the map step, you will parse JSON response instead of XML.
For each marker, create custom markers (C for campground, P for Park) and an info window that will display name and adress information when clicked on the marker.
You can center the map around your favorite city and manually insert 5-10 different markers (favorite campgrounds and parks in/around the chosen city) into the database table.
Reviews
There are no reviews yet.