summaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorbfabiszewski <github@ushuaia.pl>2013-06-23 23:43:09 +0200
committerbfabiszewski <github@ushuaia.pl>2013-06-23 23:43:09 +0200
commit6549528204f8f01bf363a26081bb1a72df2cac65 (patch)
tree3bf2f00cd8e0c88df34d00d2dbdd31a928ba27ff /index.php
parentbf662e9949165d792c8d3d4fc5b6b9d1fa1e6ab6 (diff)
downloadRunnerUpLive-6549528204f8f01bf363a26081bb1a72df2cac65.zip
store preferences in cookies
Diffstat (limited to 'index.php')
-rwxr-xr-xindex.php33
1 files changed, 31 insertions, 2 deletions
diff --git a/index.php b/index.php
index 9919f8b..0a1da1c 100755
--- a/index.php
+++ b/index.php
@@ -71,13 +71,35 @@ $track_form .= '
$api_form = '
<u>'.$lang_api.'</u><br />
<form>
-<select name="track" onchange="loadMapAPI(this.options[this.selectedIndex].value);">
+<select name="api" onchange="loadMapAPI(this.options[this.selectedIndex].value);">
<option value="gmaps"'.(($mapapi=="gmaps")?' selected':'').'>Google Maps</option>
<option value="openlayers"'.(($mapapi=="openlayers")?' selected':'').'>OpenLayers</option>
</select>
</form>
';
+// language select form
+$lang_form = '
+<u>'.$lang_language.'</u><br />
+<form>
+<select name="units" onchange="setLang(this.options[this.selectedIndex].value);">
+<option value="en"'.(($lang=="en")?' selected':'').'>English</option>
+<option value="pl"'.(($lang=="pl")?' selected':'').'>Polski</option>
+<option value="de"'.(($lang=="de")?' selected':'').'>Deutsch</option>
+</select>
+</form>
+';
+// units select form
+$units_form = '
+<u>'.$lang_units.'</u><br />
+<form>
+<select name="units" onchange="setUnits(this.options[this.selectedIndex].value);">
+<option value="metric"'.(($units=="metric")?' selected':'').'>'.$lang_metric.'</option>
+<option value="imperial"'.(($units=="imperial")?' selected':'').'>'.$lang_imperial.'</option>
+</select>
+</form>
+';
+
print
'<!DOCTYPE html>
<html>
@@ -109,6 +131,7 @@ print
var layer_ocm = "'.$layer_ocm.'";
var layer_mq = "'.$layer_mq.'";
var layer_osmapa = "'.$layer_osmapa.'";
+ var layer_ump = "'.$layer_ump.'";
</script>
<script type="text/javascript" src="main.js"></script>
';
@@ -149,8 +172,14 @@ print '
<div id="api">
'.$api_form.'
</div>
+ <div id="lang">
+ '.$lang_form.'
+ </div>
+ <div id="units">
+ '.$units_form.'
+ </div>
<div id="export">
- <u>'.$lang_download.'</u><br />
+ <u>'.$lang_download.'</u><br />
<a href="javascript:void(0);" onclick="load(\'kml\',userid,trackid)">kml</a><br />
<a href="javascript:void(0);" onclick="load(\'gpx\',userid,trackid)">gpx</a><br />
</div>