<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"
https://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="
https://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>Google Maps JavaScript API Example</title>
<script src="
https://maps.google.com/maps?file=api&v ... xxxxxxxxxx"
type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
var geocoder = null;
function load() {
if (GBrowserIsCompatible()) {
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(<?php
$adresse_google = explode('<br>',$location['53773 Hennef']);
$fp = "
https://maps.google.com/maps/geo?q=" . str_replace(' ', '+',$adresse_google[0]) . "," . str_replace(' ', '+',$adresse_google[1]) . "&output=csv&key=" . $gkey;
$map_content = explode(',',file_get_contents($fp));
echo $map_content[2] . ',' . $map_content[3];
?>), 15);
map.addControl(new GSmallZoomControl());
//map.addControl(new GMapTypeControl());
map.addOverlay(new GMarker(new GLatLng(<?php echo $map_content[2] . ',' . $map_content[3]; ?>)));
geocoder = new GClientGeocoder();
}
}
//]]>
</script>
</head>
<body onload="load()" onunload="GUnload()">
<div id="map" style="width: 500px; height: 300px"></div>
</body>
</html>
Da passiert gar nichts. (der Key war natürlich beim Test drin)
