Demo

LocationBox JavaScript Demos

Add Earthquakes

Add Earthquakes:   Remove:  

Instructions

Use the "Add" button to add earthquakes on the map. Use "Remove" button to remove the layer.

Source Code

The Javascript code for the above map is:

<script language="Javascript" 
	src="http://www.locationbox.com.tr/locationbox/services?
	Key=key&Cmd=APIV2&Typ=JS"></script>

<script language="JavaScript">
var mapper  = new IMapper();

function startup() {
  mapper.initMap(40.631, 29.027, 11);
  return;
} 

function add() {
  mapper.addEarthquakes();
  return;
 }

function remove() {
  mapper.removeEarthquakes();
  return;
 }

</script>

Download working page
Remember that you need to use your key code as Key attribute.