summaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorChristian Pointner <equinox@ffgraz.net>2008-12-15 02:45:48 +0000
committerChristian Pointner <equinox@ffgraz.net>2008-12-15 02:45:48 +0000
commitadb1a800ecd09ca405a57312a5c2b1b4e19e612a (patch)
tree486230e4d56e0f8b51f4d103024daf857bb345af /index.php
parent743233e0d4dc261e4a4ab78220b7ddc4593b273e (diff)
maps supports multiple server names
Diffstat (limited to 'index.php')
-rw-r--r--index.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/index.php b/index.php
index c82da85..a81aa38 100644
--- a/index.php
+++ b/index.php
@@ -7,6 +7,13 @@ if(isset($_REQUEST['res'])) $res = $_REQUEST['res'];
if(empty($lat)) $lat=47.07102;
if(empty($lng)) $lng=15.440;
if(empty($res)) $res=15;
+
+$apikey = 'unknownhost';
+if($_SERVER['HTTP_HOST'] == 'dev-karte.ffgraz.net') {
+ $apikey = 'ABQIAAAAZRu0cBQNp9TOBJp1i-DhohS9pf3riiZoWFmOpEuQ19If-UHZjhRHIGQIC00eY1H5H71yDqx-QzdyJA';
+} elseif($_SERVER['HTTP_HOST'] == 'dev-karte.graz.funkfeuer.at') {
+ $apikey = 'ABQIAAAAZRu0cBQNp9TOBJp1i-DhohSbKGG4yPVU7VmuBMuIIaQfSNuMAxRrbvJwWee4f-0iW-LpRZkkrl531Q';
+}
?>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">
@@ -14,7 +21,7 @@ if(empty($res)) $res=15;
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>Funkfeuer Graz: Map</title>
<link rel="stylesheet" href="map.css" type="text/css" />
- <script src="http://maps.google.com/maps?file=api&v=2&amp;&key=ABQIAAAAZRu0cBQNp9TOBJp1i-DhohS9pf3riiZoWFmOpEuQ19If-UHZjhRHIGQIC00eY1H5H71yDqx-QzdyJA"
+ <script src="http://maps.google.com/maps?file=api&v=2&amp;&key=<?php echo $apikey; ?>"
type="text/javascript"></script>
<script src="map.js" type="text/javascript"></script>
<script type="text/javascript">