Google Maps Directions to Your Business
Want to give your PURL visitors directions from their address to your business. Google Maps API makes this extremely easy!
1. Obtain an API Key
To create your API key, visit the APIs Console at https://code.google.com/apis/console and log in with your Google Account.
Click the Services link from the left-hand menu, then activate the Google Maps API v2 service.
Once the service has been activated, your API key is available from the API Access page, in the Simple API Access section. Maps API applications use the Key for browser apps.
2. Open the index.php (PURL Landing Page) to edit.
You'll need to open your index.php landing page to add the API to your PURL landing page. If you installed the campaign on your server, this page is located at in a folder named purlpage_<your campaign> If you used InstantPURL™, request FTP access (In Purlem's dashboard, click on the Landing Page tab > Request FTP Access)
Replace <Your API Key from Step 1> and <Your Address You Want Directions To> with the appropriate values.
4. Replace <body> tag
Replace the <body> tag with: <body onload="initialize()" onunload="GUnload()">
5. Display the Map and Directions
Add the code below where you would like to map and directions to appear.
<div id="map_canvas" style="width: 500px; height: 300px"></div> <div id="route"></div>
6. That's It!
Save your work, upload, sit back and admire your handy work!