6c6
<
---
>
17,18d16
< var placet=new Array();
<
22,25d19
< var wasresult="";
< var ifol=false;
< var airbit='intair.php'; //?num=4&lat=34&long=26'
<
42,88d35
< var ourlat, ourlong;
< var url = "http://www.rjmprogramming.com.au/PHP/Map/map.php?title=Airports&label=['Lat',&value='Lon','Name']&data=,[51.5072,-0.1275,~London~]";
<
< var retx = 0.0, rety = 0.0;
<
< function prereturnxy(inlatinlongthis) {
< //alert(inlatinlongthis.title);
< var prestuff = inlatinlongthis.title.split(",");
< if (prestuff.length == 2) {
< //alert(prestuff[0]);
< return returnxy(prestuff[0], prestuff[1]);
< }
< return "0.0,0.0";
< }
<
< function returnxy(inlat, inlong) {
< var retval="0.0,0.0";
<
< var ourx = eval((londonx + eval(((inlong) - (0.0)) * ((348.0 * (londonx / london_x))) / (147.325))));
< var oury = eval((londony + eval(((inlat) - (51.5)) * ((257.0 * (londony / london_y))) / (-94.3806))));
<
< retx = ourx;
< rety = oury;
<
< retval = ourx + "," + oury;
<
< if (context != null) context.fillStyle = '#0000ff';
< if (context != null) context.fillRect(retx, rety, 5, 5);
<
< return retval;
< }
<
< function sepfrom(fromo) {
< if (document.getElementById('sfrom').value != "") {
< var cs=(fromo.options[fromo.selectedIndex].title).split(",");
< airbit='intair.php?num=4&lat=' + cs[0] + '&long=' + cs[1];
< doairbit("place");
< }
< }
<
< function septo(too) {
< if (document.getElementById('sto').value != "") {
< var cs=(too.options[too.selectedIndex].title).split(",");
< airbit='intair.php?num=4&lat=' + cs[0] + '&long=' + cs[1];
< doairbit("to");
< }
< }
97,98d43
< airbit='intair.php?num=4&lat=' + cs[0] + '&long=' + cs[1];
< doairbit("place");
170c115
< var iois=document.getElementById('myxiframe');
---
> var iois=document.getElementById('myiframe');
173c118
< var tablestuff="
| Time Zone ID | Daylight Saving Time (Now) | Greenwich Mean Time(zone) |
|---|
";
---
> var tablestuff="| Time Zone ID | Daylight Saving Time (Now) | Greenwich Mean Time(zone) |
|---|
";
214,217d158
< if (wasresult == "") {
< wasresult=document.getElementById('result').innerHTML;
< startTime();
< }
227c168
< document.getElementById('myxiframe').src="./daylight_saving_time.php?url=" + encodeURIComponent('http://gomashup.com/json.php?fds=geo/timezone/gmt/' + timezone + '&jsoncallback=?');
---
> document.getElementById('myiframe').src="./daylight_saving_time.php?url=" + encodeURIComponent('http://gomashup.com/json.php?fds=geo/timezone/gmt/' + timezone + '&jsoncallback=?');
258d198
< var iplacet=placet.length;
266c206
< var pk, pktwo, thisregion=document.getElementById('region').value;
---
> var thisregion=document.getElementById('region').value;
293,303d232
< if (1 == 1) {
< pk=aconto.body.innerHTML.split(' "' + tpl[0] + '", "DST" : "');
< if (pk.length > 1) {
< pktwo=pk[1].split('"');
< placet.push(pktwo[0].replace("−", "-") + ":" + tpl[0].replace(afters[0] + '/', ''));
< } else {
< placet.push(thistimezone.replace("−", "-") + ":" + tpl[0].replace(afters[0] + '/', ''));
< }
< } else {
< placet.push(thistimezone.replace("−", "-") + ":" + tpl[0].replace(afters[0] + '/', ''));
< }
356,357c285
< }
< sepfrom(document.getElementById('sfrom'));
---
> }
440,442d367
< if (selidis.indexOf("from") == -1) {
< septo(document.getElementById('sto'));
< }
457,459d381
< if (selidis.indexOf("from") == -1) {
< septo(document.getElementById('sto'));
< }
474,530d395
< function doairbit(which) {
< if (which == "") which="place";
< var other=which.replace("place", "sfrom").replace("to", "sto");
< document.getElementById('result').innerHTML=wasresult;
< document.getElementById('myiframe').style.display='block';
< //document.getElementById('myiframe').style.top='350px';
< //document.getElementById('myiframe').style.left='10px';
< document.getElementById('myiframe').style.width='430px';
< document.getElementById('myiframe').style.height='400px';
< if (document.getElementById(other).value != '') {
< if (document.getElementById(which).value != '' && document.getElementById(other).value.indexOf("/" + document.getElementById(which).value) != -1) {
< document.getElementById('myiframe').src="http://www.rjmprogramming.com.au/PHP/Map/map.php?title=" + document.getElementById(which).value.replace("_"," ").replace("_"," ").replace("_"," ").replace("_"," ") + " Airports&label=['Lat',&value='Lon','Name']&data="; //url;
< } else {
< document.getElementById('myiframe').src="http://www.rjmprogramming.com.au/PHP/Map/map.php?title=" + document.getElementById(other).value.replace("_"," ").replace("_"," ").replace("_"," ").replace("_"," ") + " Airports&label=['Lat',&value='Lon','Name']&data="; //url;
< }
< } else {
< document.getElementById('myiframe').src="http://www.rjmprogramming.com.au/PHP/Map/map.php?title=" + document.getElementById(which).value.replace("_"," ").replace("_"," ").replace("_"," ").replace("_"," ") + " Airports&label=['Lat',&value='Lon','Name']&data="; //url;
< }
< document.getElementById('mypiframe').src=airbit;
< }
<
< function startTime() { // Thanks to http://www.w3schools.com/js/tryit.asp?filename=tryjs_timing_clock
< var today = new Date();
<
< // Thanks to http://stackoverflow.com/questions/11124322/get-date-time-for-a-specific-time-zone-using-javascript
< var localoffset = -(today.getTimezoneOffset()/60);
< var destoffset = 0;
< var placebit = '';
<
< if (placet.length > 1) {
< var numis=Math.floor(Math.random() * placet.length);
< var pbits=placet[numis].split(':');
< if (pbits.length > 1) {
< destoffset = eval(pbits[0]);
< placebit = lastbit(pbits[1]).replace("_", " ").replace("_", " ").replace("_", " ").replace("_", " ").replace("_", " ") + ": ";
< }
< }
<
< var offset = destoffset-localoffset;
< var d = new Date( new Date().getTime() + offset * 3600 * 1000);
<
< var h = d.getHours();
< var m = d.getMinutes();
< var s = d.getSeconds();
< m = checkTime(m);
< s = checkTime(s);
< if (document.getElementById('result').innerHTML == wasresult || document.getElementById('result').innerHTML.indexOf("