<html lang="en"> <head> <meta charset="utf-8"> <title>Event Listeners - <?php echo PAGE_TITLE; ?> </title> <link rel="stylesheet" type="text/css" href="_css/style.css"> <script type="text/javascript"> function add_marker( event ) { markers = []; var marker = new google.maps.Marker({ position: event.latLng, animation: google.maps.Animation.DROP, map: <?php echo $map->getJsVar(); ?> }); markers.push(marker); var info_window = <?php echo $map->getInfoWindowJsVar(); ?> ; google.maps.event.addListener( marker, 'click', function() { info_window.setContent('You clicked: ' + event.latLng.lat() + ', ' + event.latLng.lng()); info_window.open(<?php echo $map->getJsVar(); ?>