<?php
//$siteTitle = "werfg";
?>
<!DOCTYPE html "-//W3C//DTD XHTML 1.0 Strict//EN" "
http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="
http://www.w3.org/1999/xhtml"> <html>
<head>
<link rel="shortcut icon" href="favicon.ico" >
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="Rejsemappen.dk - din rejse på nettet. Brug den før, under og efter din rejse med artikler, anmeldelser, nyheder, billeder osv." />
<meta name="keywords" content="rejser, rejse, artikler, anmeldelser, billeder, dagbog, dagbøger, " />
<link href="/images/favicon.ico" rel="icon" type="image/x-icon" />
<link href="/images/favicon.ico" rel="shortcut icon" type="image/x-icon" />
<link rel="stylesheet" href="/css/default.css" type="text/css" media="screen" />
<link rel="stylesheet" href="/css/print.css" type="text/css" media="print" />
<title>Rejsemappen.dk - <?php print $siteTitle;?></title>
<script src="
http://maps.google.com/maps?file=api&v=1&key=ABQIAAAAW5DRu2-9fxxXfIdwitFJaBRae5lU3eMqtUWnF6oLMf7orc8ZxBTA9XJbgWvU_ehOBZqy7F4XYZKA7Q" type="text/javascript"></script>
<!--<script type="text/javascript" src="
http://maps.google.com/maps?file=api&v=2&key=ABQIAAAAW5DRu2-9fxxXfIdwitFJaBRae5lU3eMqtUWnF6oLMf7orc8ZxBTA9XJbgWvU_ehOBZqy7F4XYZKA7Q&sensor=true">--> <script language="javascript" src="/include/postcode.js" type="text/javascript"></script>
<script language="javascript" src="/include/calendar.js" type="text/javascript"></script>
<!--<script language="JavaScript" src="/include/simpleCalendar.js" type="text/javascript"></script>-->
</head>
<body id="bodySite">
<table><td>
<div id="map_Google" style="width: 600px; height: 400px; position: relative;"></div>
<form>
Longitude: <textarea id="long"></textarea>
Latitude: <input type="text" id="lat" />
</form>
</td></table>
<script type="text/javascript">
var map = new GMap2(document.getElementById("map_Google"));
map.setCenter(new GLatLng(37.4419, -122.1419), 8);
var marker;
map.addControl(new GMapTypeControl());
map.addControl(new GLargeMapControl());
map.enableScrollWheelZoom();
GEvent.addListener(map, 'click', function(overlay, point) {
if (point) {
map.panTo(point);
marker = new GMarker(point, {draggable: true});
map.addOverlay(marker);
document.getElementById("long").value=point.y;
document.getElementById("lat").value=point.x;
document.getElementById("submit").type='submit';
}
});
GEvent.addListener(marker, "dragstart", function() {
document.getElementById("long").value=point.y;
document.getElementById("lat").value=point.x;
map.closeInfoWindow();
});
GEvent.addListener(marker, "dragend", function(marker) {
point = marker.getLatLng();
document.getElementById("long").value=point.y;
document.getElementById("lat").value=point.x;
document.getElementById("submit").type='submit';
});
GEvent.addListener(marker, "click", function() {
var myHtml = "<b>#</b>";
marker.openInfoWindowHtml(myHtml);
});
</script>
</body>
</html>
Jeg kan godt indsætte flere "markers", men kan ikke tilføje beskrivelse til markeren, indsætte i en DB, eller slette markeren!?