PDA

View Full Version : How do I get google maps to work with with cfmap ?



Brian
January 31st, 2010, 12:46 PM
The common problem is placing your googlemapkey in your application.cfm file. Instead, place the googlemapkey in an application.cfc file. You can leave your application.cfm as it is, and just create an application.cfc if you don't have one, and take the googlemapkey out of your application.cfm file and place it in your application.cfc file.

For example, this would go in your application.cfc file:

<cfset this.googlemapkey="abc123...your google key here...789xyz">


Then in your cfm file that you want the map to display on, you would add code to it like:

<cfmap name="themap" centeraddress="Tulsa, OK" width="400" height="400" zoomlevel="9">