Europe/Amsterdamoption value=\"Pacific/Fiji\" data-geo=\"-18.13334,178.41666,+12,FJ,+13\">Pacific/Fiji"; $lastcode=''; $lastcountrycode=' '; $lastcountry=''; $lastplace=''; $screenheight='0'; // ;Continent;CC1|CC2|:blLAT,blLONG,trLAT,trLONG:width,height:scblX,scblY,sctrX,sctrY $continfo=';Europe;IS|CY|:35.16666,-27.6,67.0,33.36666:468,450:422,560,890,140'; // 53 523 $continfo.=';Australia;AU|AU|:-44,113.65,-10.26667,161.28333:600,450:422,560,866,140'; $continfo.=';Asia;FI|WS|:-14,37,81,179.9:600,450:422,560,866,140'; $continfo.=';America;GS|US|:-56,-179.9,77,-35:600,450:422,560,866,140'; $continfo.=';Africa;TF||:-35,-17,37,52:600,450:422,560,890,140'; if (isset($_GET['nothing'])) { exit; } else if (isset($_GET['returnxytoparent']) || (isset($_POST['returnxytoparent']) && !isset($_POST['ix']))) { if (isset($_GET['returnxytoparent'])) { if (isset($_GET['screenheight'])) { $screenheight=str_replace('+',' ',urldecode($_GET['screenheight'])); } if (strpos(str_replace('+',' ',urldecode($_GET['returnxytoparent'])), '&chld=') !== false && strpos(str_replace('+',' ',urldecode($_GET['returnxytoparent'])), '&chld=&') === false) { $lastcountrycode=strtoupper(substr(explode('&chld=', str_replace('+',' ',urldecode($_GET['returnxytoparent'])))[1],0,2)); for ($ihuh=0; $ihuh -91 && gextras.indexOf(' (') != -1) { // Airports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=3&lat=' + latdeg + '&long=' + longdeg + '&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Airports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'P' && latdeg >= -91 && gextras.indexOf(' (') != -1) { // Ports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=4&lat=' + latdeg + '&long=' + longdeg + '&port=y&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Ports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'S' && latdeg > -91 && gextras.indexOf(' (') != -1) { // Sun Angle window.open('//www.rjmprogramming.com.au/PHP/SunAngle/sun_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'M' && latdeg > -91 && gextras.indexOf(' (') != -1) { // Moon Angle window.open('//www.rjmprogramming.com.au/PHP/MoonAngle/moon_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'C' && latdeg > -91 && gextras.indexOf(' (') != -1) { // Coriolis Effect window.open('//www.rjmprogramming.com.au/PHP/Coriolis/coriolis_force_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'E' && latdeg > -91 && gextras.indexOf(' (') != -1) { // Google Earth window.open('//earth.google.com/web/@' + ('+' + latdeg).replace('+-','-') + (',+' + longdeg).replace('+-','-') + ',328.51120179a,63169669.71505167d,1y,0h,0t,0r','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'O' && latdeg > -91 && gextras.indexOf(' (') != -1) { // Geo Chart window.open('//www.rjmprogramming.com.au/PHP/GeoChart/geo_chart.php' + '?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '&aregexographicals=y&aregeographicals=&width=500&height=312&onclick=y&country=Places&popularity=&data=%20[' + latdeg + '|' + longdeg + '|~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~,2]','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'J' && eval(('' + document.getElementById('myp').getAttribute('data-fc')).length) == 2) { // GeoJSON //window.open('//www.rjmprogramming.com.au/HTMLCSS/countries.html','ifcountries','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); //alert(1); twomw=document.getElementById('myp').getAttribute('data-fc').substring(0,2).toUpperCase(); document.getElementById('placegeo').value='' + latdeg + ',' + longdeg; document.getElementById('placegeo').title=''; if ((latdeg < -990 && longdeg < -990) || gextras.trim() == '') { jjans=jjans + ' '; } //alert(11); if (sofararealist.indexOf('|' + ('' + twomw.substring(0,2).toUpperCase() + ' ').toUpperCase().substring(0,2).trim() + '|') == -1) { sofararealist+=('' + twomw.substring(0,2).toUpperCase() + ' ').toUpperCase().substring(0,2).trim() + '|'; } //alert(111); //document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); //document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && document.getElementById('ifcountries').src.indexOf('?') != -1 && document.getElementById('ifcountries').src.indexOf('/countries.') != -1) { document.getElementById('placegeo').value=''; document.getElementById('placegeo').title='' + latdeg + ',' + longdeg; sofararealist+=('' + lastcode + ' ').toUpperCase().substring(0,2).trim() + '|'; zoomword='zoom'; refreshword='refresh'; document.getElementById('ifcountries').src+=lhit('#' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564)); } else { document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); } lastr=rdescis; //alert(1111); if ((latdeg < -990 && longdeg < -990) || blurbone == '') { if (confirm('Taking you to ' + decodeURIComponent(rdescis) + ' on world map now' + blurbone + ' ...')) { document.getElementById('ifcountries').style.display='block'; //document.getElementById('more').style.display='none'; location.href='#ifcountries'; } } else { //alert(11111); jjans=jjans.replace(/\ \ \ \ \ $/g,''); jjans=prompt('Taking you to ' + decodeURIComponent(rdescis) + ' on world map now' + blurbtwo + ' ...', '' + jjans); if (jjans != null) { //alert(11111); document.getElementById('ifcountries').style.display='block'; //document.getElementById('more').style.display='none'; location.href='#ifcountries'; } } } // new //} } function okd(e){ var charx = e.which || e.keyCode; var latdeg=-999, longdeg=-999; if (gextras.indexOf(' (') != -1) { if (gextras.split('t to (')[1].split(')')[0].indexOf(',') != -1) { latdeg=eval('' + gextras.split('t to (')[1].split(')')[0].split(',')[0]); longdeg=eval('' + gextras.split('t to (')[1].split(')')[0].split(',')[1]); } } else if (storedsuffs.indexOf('~' + lpw(lastplace) + '`') != -1 && storedsuffs.indexOf('~' + lpw(lastplace) + '`|') == -1) { gextras=storedsuffs.split('~' + lpw(lastplace) + '`')[1].split('`')[0].split('~')[0]; //.split('|')[0]; if (gextras.split(' (')[1].split(')')[0].indexOf(',') != -1) { latdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[0]); longdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[1]); } } if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { charx=charx; } else if (('' + e.keyCode) == '87') { // Wikipedia menuize('W'); } else if (('' + e.keyCode) == '89') { // YouTube menuize('Y'); } else if (('' + e.keyCode) == '84') { // TimeZone tz_places.php menuize('T'); } else if (('' + e.keyCode) == '71') { // Google menuize('G'); } else if (latdeg > -91) { if (('' + e.keyCode) == '65') { // Airports menuize('A'); } else if (('' + e.keyCode) == '83') { // Sun Angle menuize('S'); } else if (('' + e.keyCode) == '77') { // Moon Angle menuize('M'); } else if (('' + e.keyCode) == '80') { // Ports menuize('P'); } else if (('' + e.keyCode) == '67') { // Coriolis menuize('C'); } else if (('' + e.keyCode) == '69') { // Google Earth menuize('E'); } else if (('' + e.keyCode) == '79') { // Geo Chart menuize('O'); } //} else if (('' + e.keyCode) == '65') { // Airports //alert('storedsuffs=' + storedsuffs + ' and lastplace=' + lastplace); } return true; } function doslptc(cnameis, ccodeis) { lastcode=ccodeis; lastplace=cnameis; if (('' + ccodeis + ' ').substring(2).substring(0,1) == '-') { lastcountrycode=ccodeis.substring(0,2).toUpperCase(); } else if (eval('' + ccodeis.length) == 2) { lastcountrycode=ccodeis.toUpperCase(); } if (cnameis.indexOf(' (') != -1 && cnameis.replace(/\ /g,'').indexOf('()') == -1) { lastcountry=cnameis.split(' (')[1].split(')')[0]; } if (window.opener) { window.opener.slptc(cnameis, ccodeis); } else if (window.parent) { parent.slptc(cnameis, ccodeis); } return cnameis; } function pax(sxis) { if (window.opener) { window.opener.sxiss(sxis); } else if (window.parent) { parent.sxiss(sxis); } return sxis; } function paa(syis) { if (window.opener) { window.opener.syiss(syis); } else if (window.parent) { parent.syiss(syis); } return syis; } function rgbToHex(r, g, b) { // thanks to https://stackoverflow.com/questions/6735470/get-pixel-color-from-canvas-on-mousemove if (r > 255 || g > 255 || b > 255) throw 'Invalid color component'; return ((r << 16) | (g << 8) | b).toString(16); } function filloutform(e,isclick) { var p='', hex='', myid=''; var browserZoomLevel = Math.round(window.devicePixelRatio * 100); browserZoomLevel=1; e = e || window.event; e.preventDefault(); if (e.touches) { if (e.touches[0].pageX) { //document.getElementById('myspan').innerHTML+='
                    1:' + e.touches[0].pageY + ' ' + browserZoomLevel + ' ' + document.body.scrollTop; x = eval(e.touches[0].pageX + document.body.scrollLeft) * browserZoomLevel; y = eval(e.touches[0].pageY + document.body.scrollTop) * browserZoomLevel; xs = pax(e.touches[0].screenX); ys = paa(e.touches[0].screenY); } else { //document.getElementById('myspan').innerHTML+='
                    ' + '2:' + e.touches[0].clientY + ' ' + browserZoomLevel + ' ' + document.body.scrollTop; x = eval(e.touches[0].clientX + document.body.scrollLeft) * browserZoomLevel; y = eval(e.touches[0].clientY + document.body.scrollTop) * browserZoomLevel; xs = pax(e.touches[0].screenX); ys = paa(e.touches[0].screenY); } console.log('pos3=' + pos3 + ',pos4=' + pos4); } else if (e.clientX || e.clientY) { //document.getElementById('myspan').innerHTML+='
                    ' + '3:' + e.clientY + ' ' + browserZoomLevel + ' ' + document.body.scrollTop; x = e.clientX + document.body.scrollLeft; y = e.clientY + document.body.scrollTop; xs = pax(e.screenX); ys = paa(e.screenY); } else { //document.getElementById('myspan').innerHTML+='
' + '4:' + e.pageY + ' ' + browserZoomLevel + ' ' + document.body.scrollTop; x = e.pageX + document.body.scrollLeft; x = e.pageY + document.body.scrollTop; xs = pax(e.screenX); ys = paa(e.screenY); } console.log('xs=' + xs + ' and ys=' + ys); if (eval('' + x) > 2 && eval('' + y) > 2) { document.getElementById('ix').value='' + x; document.getElementById('iy').value='' + y; if (document.getElementById('imode').value == 'click' && isclick != 0) { document.getElementById('imode').value='click'; if (!context) { thisonl(); } p = context.getImageData(x, y, 1, 1).data; hex = ('#' + ('000000' + rgbToHex(p[0], p[1], p[2])).slice(-6)).toUpperCase(); document.getElementById('moimode').value='mouseover'; myid=''; if (document.getElementById('myp').innerHTML.indexOf(hex) != -1) { myid=document.getElementById('myp').innerHTML.split(hex)[0].split(' id=\"')[eval(-1 + document.getElementById('myp').innerHTML.split(hex)[0].split(' id=\"').length)].split('\"')[0]; document.getElementById('ici').title=doslptc(document.getElementById(myid).title, myid.substring(1)); document.getElementById(myid).click(); } else if (document.getElementById('myp').innerHTML.indexOf(hex.toLowerCase()) != -1) { myid=document.getElementById('myp').innerHTML.split(hex.toLowerCase())[0].split(' id=\"')[eval(-1 + document.getElementById('myp').innerHTML.split(hex.toLowerCase())[0].split(' id=\"').length)].split('\"')[0]; //document.title='x=' + x + ' and y=' + y + ' ' + hex; document.getElementById('ici').title=doslptc(document.getElementById(myid).title, myid.substring(1)); document.getElementById(myid).click(); } else if (hex.toUpperCase() != '#D0D0D0' && hex.toUpperCase() != '#FFFFFF' && hex.toUpperCase() != '#000000' && hex.toUpperCase() != '#B3BCC0' && hex.toUpperCase() != '#BCBCBC') { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { // alert('origtitle=' + origtitle + ' and ' + document.getElementById('ici').title + ' and hex=' + hex); //} if (document.getElementById('ici').title != origtitle) { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { //document.getElementById('blastcol').click(); // document.getElementById('myform').submit(); //} else { gmenu('', document.getElementById('ici').title); //} } else { //document.getElementById('blastcol').click(); document.getElementById('myform').submit(); } } } else { document.getElementById('moix').value='' + x; document.getElementById('moiy').value='' + y; if (!context) { thisonl(); } p = context.getImageData(x, y, 1, 1).data; hex = ('#' + ('000000' + rgbToHex(p[0], p[1], p[2])).slice(-6)).toUpperCase(); document.getElementById('moimode').value='mouseover'; myid=''; if (document.getElementById('myp').innerHTML.indexOf(hex) != -1) { myid=document.getElementById('myp').innerHTML.split(hex)[0].split(' id=\"')[eval(-1 + document.getElementById('myp').innerHTML.split(hex)[0].split(' id=\"').length)].split('\"')[0]; document.getElementById('ici').title=doslptc(document.getElementById(myid).title, myid.substring(1)); } else if (document.getElementById('myp').innerHTML.indexOf(hex.toLowerCase()) != -1) { myid=document.getElementById('myp').innerHTML.split(hex.toLowerCase())[0].split(' id=\"')[eval(-1 + document.getElementById('myp').innerHTML.split(hex.toLowerCase())[0].split(' id=\"').length)].split('\"')[0]; //document.title='x=' + x + ' and y=' + y + ' ' + hex; document.getElementById('ici').title=doslptc(document.getElementById(myid).title, myid.substring(1)); } else if (document.getElementById('ici').title == origtitle) { //document.getElementById('moblastcol').click(); document.getElementById('myformmo').submit(); } } } } function latergmenu() { var rcodeis=grcodeis; var erdescis=gerdescis; var rdescis=decodeURIComponent(erdescis); document.getElementById('ici').style.cursor='pointer'; if (document.getElementById('placegeo').value.indexOf(',') != -1) { var latdeg=document.getElementById('placegeo').value.split(',')[0]; var longdeg=document.getElementById('placegeo').value.split(',')[1]; gextras='A - Airports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='S - Sun Angle at Noon at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='M - Moon Angle at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='C - Coriolis Effect at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='E - Google Earth at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='P - Ports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='O - Geo Chart at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras='A - Airports Closest to (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(2); gextras+='S - Sun Angle at Noon at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='M - Moon Angle at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(9); gextras+='C - Coriolis Effect at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='E - Google Earth at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(8); gextras+='P - Ports Closest to (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='O - Geo Chart at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')'; if (storedsuffs.indexOf('~' + lpw(lastsuff) + '`' + gextras) == -1 && storedsuffs.indexOf('~' + lpw(lastsuff) + '`|') == -1) { storedsuffs+='~' + lpw(lastsuff) + '`' + gextras + '|'; } storedsuffs=storedsuffs.replace('~' + lpw(lastsuff) + '`|', '~' + lpw(lastsuff) + '`' + gextras + '|'); if (window.opener) { window.opener.putgextras(gextras, rdescis); } else if (window.parent) { parent.putgextras(gextras, rdescis); } document.getElementById('placegeo').value=''; } else if (document.getElementById('placegeo').value == ' ') { gextras=''; if (window.opener) { window.opener.putgextras(gextras, rdescis); } else if (window.parent) { parent.putgextras(gextras, rdescis); } } if (rdescis != lastplace && lastplace.trim() != '') { rdescis=lastplace; } if ((1 == 1 || rcodeis.trim()) != '' && rdescis.trim() != '') { if (gextras.trim() == '' && storedsuffs.indexOf('~' + lpw(rdescis) + '`') != -1) { gextras=storedsuffs.split('~' + lpw(rdescis) + '`')[1].split('`')[0].split('~')[0]; //.split('|')[0]; } var rans=null; //prompt('What do you want to do with region ' + rdescis + '? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + String.fromCharCode(10) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + String.fromCharCode(10) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + String.fromCharCode(10) + 'I - Image Chart look up ' + String.fromCharCode(10) + gextras, ''); if (gextras == '') { rans=prompt('What do you want to do with region ' + rdescis + '? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + StringfromCharCode(6) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + StringfromCharCode(11) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + StringfromCharCode(9) + 'I - Image Chart look up ' + String.fromCharCode(10) + String.fromCharCode(10) + gextras, ''); } else { // Thanks to https://stackoverflow.com/questions/17779744/regular-expression-to-get-a-string-between-parentheses-in-javascript for regex below ... rans=prompt('What to do with ' + rdescis + ' at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ') ? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + StringfromCharCode(6) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + StringfromCharCode(11) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + StringfromCharCode(9) + 'I - Image Chart look up ' + String.fromCharCode(10) + gextras.replace(/\(([^)]+)\)/g, '()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()').replace('(' + ('' + latdeg).replace('.000','') + ',' + ('' + longdeg).replace('.000','') + ')','()'), ''); } if (rans == null) { rans=' '; } else if (rans.trim() != '') { rans+=gextras; } gextras=''; if ((rans + ' ').toUpperCase().substring(0,1) == 'W') { window.open('//wikipedia.org/wiki/' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'Y') { window.open('//www.rjmprogramming.com.au/HTMLCSS/karaoke_youtube_api.htm?emoji=on&nokaraoke=y&youtubeid=' + encodeURIComponent(' ' + rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'G') { window.open('//www.google.com/search?q=' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')) + '&tbm=isch','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'I' && window.opener) { window.opener.tryit(); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'I' && window.top != window.self) { top.tryit(); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'T' && eval(('' + document.getElementById('myp').getAttribute('data-fc')).length) == 2) { window.open('//www.rjmprogramming.com.au/PHP/tz_places.php?iso=' + document.getElementById('myp').getAttribute('data-fc').toUpperCase(),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'A' && rans.indexOf(' (') != -1) { // Airports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=3&lat=' + latdeg + '&long=' + longdeg + '&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Airports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'P' && rans.indexOf(' (') != -1) { // Ports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=4&lat=' + latdeg + '&long=' + longdeg + '&port=y&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Ports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'S' && rans.indexOf(' (') != -1) { // Sun Angle window.open('//www.rjmprogramming.com.au/PHP/SunAngle/sun_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'M' && rans.indexOf(' (') != -1) { // Moon Angle window.open('//www.rjmprogramming.com.au/PHP/MoonAngle/moon_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'C' && rans.indexOf(' (') != -1) { // Coriolis Effect window.open('//www.rjmprogramming.com.au/PHP/Coriolis/coriolis_force_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'E' && rans.indexOf(' (') != -1) { // Google Earth window.open('//earth.google.com/web/@' + ('+' + latdeg).replace('+-','-') + (',+' + longdeg).replace('+-','-') + ',328.51120179a,63169669.71505167d,1y,0h,0t,0r','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'O' && rans.indexOf(' (') != -1) { // Geo Chart window.open('//www.rjmprogramming.com.au/PHP/GeoChart/geo_chart.php' + '?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '&aregexographicals=y&aregeographicals=&width=500&height=312&onclick=y&country=Places&popularity=&data=%20[' + latdeg + '|' + longdeg + '|~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~,2]','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'J' && eval(('' + document.getElementById('myp').getAttribute('data-fc')).length) == 2) { // GeoJSON //window.open('//www.rjmprogramming.com.au/HTMLCSS/countries.html','ifcountries','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); //alert(1); twomw=document.getElementById('myp').getAttribute('data-fc').substring(0,2).toUpperCase(); document.getElementById('placegeo').value='' + latdeg + ',' + longdeg; document.getElementById('placegeo').title=''; if ((latdeg < -990 && longdeg < -990) || gextras.trim() == '') { jjans=jjans + ' '; } //alert(11); if (sofararealist.indexOf('|' + ('' + twomw.substring(0,2).toUpperCase() + ' ').toUpperCase().substring(0,2).trim() + '|') == -1) { sofararealist+=('' + twomw.substring(0,2).toUpperCase() + ' ').toUpperCase().substring(0,2).trim() + '|'; } //alert(111); //document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); //document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && document.getElementById('ifcountries').src.indexOf('?') != -1 && document.getElementById('ifcountries').src.indexOf('/countries.') != -1) { document.getElementById('placegeo').value=''; document.getElementById('placegeo').title='' + latdeg + ',' + longdeg; sofararealist+=('' + lastcode + ' ').toUpperCase().substring(0,2).trim() + '|'; zoomword='zoom'; refreshword='refresh'; document.getElementById('ifcountries').src+=lhit('#' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564)); } else { document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?' + (Math.max(lastiizoom,1) == 1 ? zoomword + '=' + Math.max(lastiizoom,1) : 'zoom=' + Math.max(lastiizoom,1)) + '&' + refreshword + '=' + Math.floor(Math.random() * 198767564); } lastr=rdescis; //alert(1111); if ((latdeg < -990 && longdeg < -990) || blurbone == '') { if (confirm('Taking you to ' + decodeURIComponent(rdescis) + ' on world map now' + blurbone + ' ...')) { document.getElementById('ifcountries').style.display='block'; //document.getElementById('more').style.display='none'; location.href='#ifcountries'; } } else { //alert(11111); jjans=jjans.replace(/\ \ \ \ \ $/g,''); jjans=prompt('Taking you to ' + decodeURIComponent(rdescis) + ' on world map now' + blurbtwo + ' ...', '' + jjans); if (jjans != null) { //alert(11111); document.getElementById('ifcountries').style.display='block'; //document.getElementById('more').style.display='none'; location.href='#ifcountries'; } } } // new } } function coordit(xiois) { var xaconto = (xiois.contentWindow || xiois.contentDocument); //alert(11); if (xaconto != null) { //alert('111 ' + xiois.src); if (xaconto.document) { xaconto = xaconto.document; } //alert('1111 ' + xaconto.body.innerHTML); if (xaconto.body.innerHTML.indexOf('>Coordinates') != -1) { var subpart=xaconto.body.innerHTML.split('>Coordinates')[1]; var latdeg=-999, longdeg=-999, latmin=0, longmin=0, latsec=0, longsec=0, sparelat='', sparelong=''; if (subpart.indexOf('\"latitude\"') != -1 && subpart.indexOf('\"longitude\"') != -1) { latdeg=subpart.split('\"latitude\"')[1].split('>')[1].split(\"°\")[0].split('<')[0]; sparelat=subpart.split('\"latitude\"')[1].split('>')[1].split('<')[0].slice(-1); latmin=subpart.split('\"latitude\"')[1].split('>')[1].split('<')[0].substring(eval(1 + eval('' + latdeg.length))).split(\"′\")[0].split(sparelat)[0].split('<')[0]; if (sparelat == 'S') { latdeg=eval(eval(eval(-1 * latmin) / 60) - latdeg); } else { latdeg+=eval(eval('' + latmin) / 60) } longdeg=subpart.split('\"longitude\"')[1].split('>')[1].split(\"°\")[0].split('<')[0]; sparelong=subpart.split('\"longitude\"')[1].split('>')[1].split('<')[0].slice(-1); longmin=subpart.split('\"longitude\"')[1].split('>')[1].split('<')[0].substring(eval(1 + eval('' + longdeg.length))).split(\"′\")[0].split(sparelong)[0].split('<')[0]; if (sparelong == 'W') { longdeg=eval(eval(eval(-1 * longmin) / 60) - longdeg); } else { longdeg+=eval(eval('' + longmin) / 60) } gextras='A - Airports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='S - Sun Angle at Noon at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='M - Moon Angle at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='C - Coriolis Effect at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='E - Google Earth at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='P - Ports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='O - Geo Chart at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras='A - Airports Closest to (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(2); gextras+='S - Sun Angle at Noon at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='M - Moon Angle at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(9); gextras+='C - Coriolis Effect at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='E - Google Earth at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + StringfromCharCode(8); gextras+='P - Ports Closest to (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')' + String.fromCharCode(10); gextras+='O - Geo Chart at (' + (('' + latdeg).indexOf('.') != -1 ? ('' + latdeg) : ('' + latdeg + '.000')) + ',' + (('' + longdeg).indexOf('.') != -1 ? ('' + longdeg) : ('' + longdeg + '.000')) + ')'; if (storedsuffs.indexOf('~' + lpw(lastsuff) + '`' + gextras) == -1 && storedsuffs.indexOf('~' + lpw(lastsuff) + '`|') == -1) { storedsuffs+='~' + lpw(lastsuff) + '`' + gextras + '|'; } storedsuffs=storedsuffs.replace('~' + lpw(lastsuff) + '`|', '~' + lpw(lastsuff) + '`' + gextras + '|'); if (window.opener) { window.opener.putgextras(gextras, grdescis); } else if (window.parent) { parent.putgextras(gextras, grdescis); } return true; } } else { gextras=''; if (window.opener) { window.opener.putgextras(gextras, grdescis); } else if (window.parent) { parent.putgextras(gextras, grdescis); } } } return true; } function gmenu(rcodeis, erdescis) { var rdescis=decodeURIComponent(erdescis); var latdeg=-999, longdeg=-999; if (rdescis != lastplace && lastplace.trim() != '') { rdescis=lastplace; } if (gextras.indexOf(' (') != -1) { if (gextras.split(' (')[1].split(')')[0].indexOf(',') != -1) { latdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[0]); longdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[1]); } } else if (storedsuffs.indexOf('~' + lpw(lastplace) + '`') != -1 && storedsuffs.indexOf('~' + lpw(lastplace) + '`|') == -1) { gextras=storedsuffs.split('~' + lpw(lastplace) + '`')[1].split('`')[0].split('~')[0]; //.split('|')[0]; if (gextras.split(' (')[1].split(')')[0].indexOf(',') != -1) { latdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[0]); longdeg=eval('' + gextras.split(' (')[1].split(')')[0].split(',')[1]); } } if ((1 == 1 || rcodeis.trim()) != '' && rdescis.trim() != '') { grcodeis=rcodeis; gerdescis=erdescis; grdescis=rdescis; //setTimeout(latergmenu, 8000); if (lastsuff != encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_') && storedsuffs.indexOf('~' + lpw(rdescis) + '`') == -1) { gextras=''; lastsuff=encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'); storedsuffs+='~' + lpw(rdescis) + '`' + '|'; if (storedsuffs.indexOf('~' + lpw(rdescis) + '`') != -1 && storedsuffs.indexOf('~' + lpw(rdescis) + '`|') == -1) { gextras=storedsuffs.split('~' + lpw(rdescis) + '`')[1].split('`')[0].split('~')[0]; //.split('|')[0]; //alert('rdescis=' + rdescis + ' and storedsuffs=' + storedsuffs); document.getElementById('placegeo').value=storedsuffs.split('~' + lpw(rdescis) + '`')[1].split(' (')[1].split(')')[0]; document.getElementById('placegeo').title=''; setTimeout(latergmenu, 80); } else if (1 == 11) { document.getElementById('ici').style.cursor='progress'; setTimeout(latergmenu, 8000); myxhr = new XMLHttpRequest(); myxhr.open('GET', '//en.wikipedia.org/wiki/' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'), true); myxhr.responseType = 'text'; myxhr.onreadystatechange=stateChanged; myxhr.send(null); } else if (11 == 11) { document.getElementById('ici').style.cursor='progress'; setTimeout(latergmenu, 8000); document.getElementById('placegeo').value=' '; document.getElementById('wif').src='/PHP/fgc/index.php?placegeo=' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'); } else { document.getElementById('ici').style.cursor='progress'; setTimeout(latergmenu, 8000); document.getElementById('wif').src='//en.wikipedia.org/wiki/' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'); } } else { if (storedsuffs.indexOf('~' + lpw(rdescis) + '`') != -1) { gextras=storedsuffs.split('~' + lpw(rdescis) + '`')[1].split('`')[0].split('~')[0]; } var rans=null; //prompt('What do you want to do with region ' + rdescis + '? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + String.fromCharCode(10) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + String.fromCharCode(10) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + StringfromCharCode(10) + 'I - Image Chart look up ' + String.fromCharCode(10) + gextras, ''); if (gextras == '') { rans=prompt('What do you want to do with region ' + rdescis + '? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + StringfromCharCode(6) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + StringfromCharCode(11) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + StringfromCharCode(9) + 'I - Image Chart look up ' + String.fromCharCode(10) + String.fromCharCode(10) + gextras, ''); } else { //alert(storedsuffs); rans=prompt('What to do with ' + rdescis + ' at (' + latdeg + ',' + longdeg + ') ? ' + String.fromCharCode(10) + String.fromCharCode(10) + 'W - Wikipedia look up ' + StringfromCharCode(6) + 'Y - YouTube look up ' + String.fromCharCode(10) + 'G - Google look up ' + StringfromCharCode(11) + 'T - TimeZone look up ' + String.fromCharCode(10) + 'J - GeoJson look up ' + StringfromCharCode(9) + 'I - Image Chart look up ' + String.fromCharCode(10) + gextras.replace(/\(([^)]+)\)/g, '()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()').replace('(' + latdeg + ',' + longdeg + ')','()'), ''); } if (rans == null) { rans=' '; } else if (rans.trim() != '') { rans+=gextras; } if ((rans + ' ').toUpperCase().substring(0,1) == 'W') { window.open('//wikipedia.org/wiki/' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')).replace(/\%20/g,'_'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'Y') { window.open('//www.rjmprogramming.com.au/HTMLCSS/karaoke_youtube_api.htm?emoji=on&nokaraoke=y&youtubeid=' + encodeURIComponent(' ' + rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'G') { window.open('//www.google.com/search?q=' + encodeURIComponent(rdescis.replace(/\ \(/g,', ').replace(/\)$/g,'')) + '&tbm=isch','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'T' && eval(('' + document.getElementById('myp').getAttribute('data-fc')).length) == 2) { window.open('//www.rjmprogramming.com.au/PHP/tz_places.php?iso=' + document.getElementById('myp').getAttribute('data-fc').toUpperCase(),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'A' && rans.indexOf(' (') != -1) { // Airports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=3&lat=' + latdeg + '&long=' + longdeg + '&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Airports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'P' && rans.indexOf(' (') != -1) { // Ports window.open('//www.rjmprogramming.com.au/HTMLCSS/intair.php?num=4&lat=' + latdeg + '&long=' + longdeg + '&port=y&spawn=' + encodeURIComponent('//www.rjmprogramming.com.au/PHP/Map/map.php?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis) + '%' + '20and%' + '20Ports&onclick=y&justmenu=y&label=[%' + '27Lat%' + '27,&value=%' + '27Lon%' + '27,%' + '27Name%' + '27]&data=,' + '[' + latdeg + ',' + longdeg + ',~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~]'),'_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'S' && rans.indexOf(' (') != -1) { // Sun Angle window.open('//www.rjmprogramming.com.au/PHP/SunAngle/sun_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'M' && rans.indexOf(' (') != -1) { // Moon Angle window.open('//www.rjmprogramming.com.au/PHP/MoonAngle/moon_angle_now_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'C' && rans.indexOf(' (') != -1) { // Coriolis Effect window.open('//www.rjmprogramming.com.au/PHP/Coriolis/coriolis_force_at.php?latd=' + ('' + latdeg).split('.')[0] + '&latm=' + Math.round(eval(eval('0.' + ('' + latdeg + '.0').split('.')[1]) * 60)) + '&lats=0&longd=' + ('' + longdeg).split('.')[0] + '&longm=' + Math.round(eval(eval('0.' + ('' + longdeg + '.0').split('.')[1]) * 60)) + '&longs=0&from=from&done=y','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'E' && rans.indexOf(' (') != -1) { // Google Earth window.open('//earth.google.com/web/@' + ('+' + latdeg).replace('+-','-') + (',+' + longdeg).replace('+-','-') + ',328.51120179a,63169669.71505167d,1y,0h,0t,0r','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } else if ((rans + ' ').toUpperCase().substring(0,1) == 'O' && rans.indexOf(' (') != -1) { // Geo Chart window.open('//www.rjmprogramming.com.au/PHP/GeoChart/geo_chart.php' + '?title=' + maybenot(document.getElementById('myp').getAttribute('data-fc').toUpperCase(),rdescis) + ';' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '&aregexographicals=y&aregeographicals=&width=500&height=312&onclick=y&country=Places&popularity=&data=%20[' + latdeg + '|' + longdeg + '|~' + encodeURIComponent(rdescis).replace(/\-/g,'%' + '2d').replace(/\#/g,'%' + '23') + '~,2]','_blank','top=' + ys + ',left=' + xs + ',width=600,height=' + Math.max(100,eval(-100 + screenheight - ys))); } } } } function maybenot(inmaybe, vspl) { var fontarr=document.getElementsByTagName('font'); for (var ifo=0; ifo 1) { origtitle=origtitle.replace('relevant region', 'relevant ' + bits[1].split('\"')[0] + ' region'); document.getElementById('ici').title=origtitle; } return inoh; } function stateChanged() { if (myxhr.readyState == 4) { if (myxhr.status == 200) { console.log('myxhr=' + myxhr); var subpart=myxhr.responseText.split('>Coordinates')[1]; var latdeg=-999, longdeg=-999, latmin=0, longmin=0, latsec=0, longsec=0, sparelat='', sparelong=''; if (subpart.indexOf('\"latitude\"') != -1 && subpart.indexOf('\"longitude\"') != -1) { latdeg=subpart.split('\"latitude\"')[1].split('>')[1].split(\"°\")[0].split('<')[0]; sparelat=subpart.split('\"latitude\"')[1].split('>')[1].split('<')[0].slice(-1); latmin=subpart.split('\"latitude\"')[1].split('>')[1].split('<')[0].substring(eval(1 + eval('' + latdeg.length))).split(\"′\")[0].split(sparelat)[0].split('<')[0]; if (sparelat == 'S') { latdeg=eval(eval(eval(-1 * latmin) / 60) - latdeg); } else { latdeg+=eval(eval('' + latmin) / 60) } longdeg=subpart.split('\"longitude\"')[1].split('>')[1].split(\"°\")[0].split('<')[0]; sparelong=subpart.split('\"longitude\"')[1].split('>')[1].split('<')[0].slice(-1); longmin=subpart.split('\"longitude\"')[1].split('>')[1].split('<')[0].substring(eval(1 + eval('' + longdeg.length))).split(\"′\")[0].split(sparelong)[0].split('<')[0]; if (sparelong == 'W') { longdeg=eval(eval(eval(-1 * longmin) / 60) - longdeg); } else { longdeg+=eval(eval('' + longmin) / 60) } gextras='A - Airports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='S - Sun Angle at Noon at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='M - Moon Angle at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='C - Coriolis Effect at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='E - Google Earth at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='P - Ports Closest to (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); gextras+='O - Geo Chart at (' + latdeg + ',' + longdeg + ')' + String.fromCharCode(10); if (storedsuffs.indexOf('~' + lpw(lastsuff) + '`' + gextras) == -1 && storedsuffs.indexOf('~' + lpw(lastsuff) + '`|') == -1) { storedsuffs+='~' + lpw(lastsuff) + '`' + gextras + '|'; } storedsuffs=storedsuffs.replace('~' + lpw(lastsuff) + '`|', '~' + lpw(lastsuff) + '`' + gextras + '|'); if (window.opener) { window.opener.putgextras(gextras, grdescis); } else if (window.parent) { parent.putgextras(gextras, grdescis); } } } } } function nospan() { if (('' + jjans).trim() == 'No Trip Planning') { document.getElementById('plots').innerHTML=''; spancount=0; } } function sein(iz) { if (!zoomdone) { zoomdone=true; setInterval(rifcheck, 15000); } return iz; } function lhit(inh) { locationhash=inh; ifcheck(document.getElementById('ifcountries')); return inh; } function rifcheck() { var waszoom=1; var xif=-999, yif=-999, xxif=-999, yyif=-999; var xlatdeg=0, xlongdeg=0; if (9 == 9) { var iiizoom=lastiizoom; if (document.getElementById('ifcountries').src.indexOf('zoom=') == -1 && document.getElementById('ifcountries').src.indexOf('refresh=') == -1) { iiizoom=eval(2 * lastiizoom); //eval('' + zawconto.getzoom()); } //alert('' + iiizoom + ' ' + lastiizoom + ' ' + document.getElementById('ifcountries').src); //alert('' + iiizoom); if (lastiizoom != iiizoom || (document.getElementById('ifcountries').src.indexOf('zoom=') != -1 && document.getElementById('ifcountries').src.indexOf('refresh=') != -1)) { var isp=0; var huhrect=document.getElementById('ifcountries').getBoundingClientRect(); var ospancount=spancount; newone=eval(1 + spancount); while (document.getElementById('span' + isp)) { if (isp < ospancount) { waszoom=document.getElementById('span' + isp).getAttribute('data-zoom'); if (waszoom != iiizoom) { //alert(67); xlatdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[0]); xlongdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[1]); //alert(167); xxif=eval(iiizoom * eval(180 + eval('' + xlongdeg))); yyif=eval(iiizoom * eval(90 - eval('' + xlatdeg))); //alert(1167); if (1 == 1) { document.getElementById('plots').innerHTML+='x'; nodiv(isp, spancount); spancount++; document.getElementById('span' + isp).style.display='none'; } else { document.getElementById('span' + isp).style.top='' + eval(eval('' + huhrect.top) + yyif) + 'px'; document.getElementById('span' + isp).style.left='' + eval(eval('' + huhrect.left) + xxif) + 'px'; document.getElementById('span' + isp).setAttribute('data-zoom', '' + iiizoom); document.getElementById('span' + isp).setAttribute('data-iframepos', '' + huhrect.left + ',' + huhrect.top); document.getElementById('sspan' + isp).innerHTML=document.getElementById('span' + isp).outerHTML; //alert(document.getElementById('sspan' + isp).innerHTML); } } } isp++; } lastiizoom=iiizoom; if (document.getElementById('ifcountries').src.indexOf('zoom=') == -1 && document.getElementById('ifcountries').src.indexOf('refresh=') == -1) { zoomword='zoom'; refreshword='refresh'; if (document.getElementById('ifcountries')) { document.getElementById('ifcountries').style.width='' + eval(2 * eval('' + document.getElementById('ifcountries').style.width.replace('px',''))) + 'px'; document.getElementById('ifcountries').style.height='' + eval(2 * eval('' + document.getElementById('ifcountries').style.height.replace('px',''))) + 'px'; } document.getElementById('ifcountries').src='//www.rjmprogramming.com.au/HTMLCSS/countries.html?zoom=' + Math.max(lastiizoom,1) + '&refresh=' + Math.floor(Math.random() * 198767564); } else { //alert('There'); //document.getElementById('more').style.left='' + eval(eval(360 * lastiizoom / 2) + eval('' + document.getElementById('more').style.left.replace('px',''))) + 'px'; var arstart=[], iars=0, iiars=0, kkfound=false; var ars=zaconto.getElementsByTagName('area'); //alert('' + ars.length + ' ' + sofararealist); for (iars=0; iars 0) { ars=zaconto.getElementsByTagName('div'); //alert('' + ars.length + ' ' + sofararealist); for (iiars=0; iiars 1 && !nolineplease) { setTimeout(function(){ drawlinebetween(spanos[eval(-2 + spanos.length)], spanos[eval(-1 + spanos.length)]); }, 5000); } } } function drawlinebetween(spanoone, spanotwo) { var xneeds=[], yneeds=[], classbit=''; if (nolineplease) { isdouble=0; nolineplease=false; return false; } if (('' + spanoone.id).indexOf('sspan') == 0) { spanoone=document.getElementById(('' + spanoone.id).replace('sspan','span')); } if (('' + spanotwo.id).indexOf('sspan') == 0) { spanotwo=document.getElementById(('' + spanotwo.id).replace('sspan','span')); } if (('' + spanoone.id).indexOf('span') == 0 && ('' + spanotwo.id).indexOf('span') == 0) { xneeds.push(eval('' + ('' + spanoone.style.left).replace('px',''))); yneeds.push(eval('' + ('' + spanoone.style.top).replace('px',''))); xneeds.push(eval('' + ('' + spanotwo.style.left).replace('px',''))); yneeds.push(eval('' + ('' + spanotwo.style.top).replace('px',''))); var divih=''; if (Math.min(xneeds[0],xneeds[1]) == xneeds[0] && Math.min(yneeds[0],yneeds[1]) == yneeds[1]) { // thanks to https://stackoverflow.com/questions/18012420/draw-diagonal-lines-in-div-background-with-css classbit=' class=\"crossedtotl\" '; } else if (Math.min(xneeds[0],xneeds[1]) == xneeds[1] && Math.min(yneeds[0],yneeds[1]) == yneeds[0]) { // thanks to https://stackoverflow.com/questions/18012420/draw-diagonal-lines-in-div-background-with-css classbit=' class=\"crossedtotl\" '; } else { classbit=' class=\"crossedtotr\" '; } if (classbit == ' class=\"crossedtotl\" ') { divih=\"\"; classbit=''; } var fcl=''; var tcl=''; if (spanoone.title.indexOf('Right click ') != -1) { spanoone.innerHTML='🔴'; fcl=' from your right click '; } else { spanoone.innerHTML='❌'; fcl=' from ' + spanoone.title + ' '; } if (spanotwo.title.indexOf('Right click ') != -1) { spanotwo.innerHTML='🔴'; tcl=' to your right click '; lastwo=\"//www.google.com/maps/dir/\" + spanoone.getAttribute('data-geo') + \"/\" + spanotwo.getAttribute('data-geo') + \"' + '#' + '\" + 'Leg' + fcl + tcl + ' heads off at ' + great_circle_bearing(spanoone.getAttribute('data-geo').split(',')[0], spanoone.getAttribute('data-geo').split(',')[1], spanotwo.getAttribute('data-geo').split(',')[0], spanotwo.getAttribute('data-geo').split(',')[1]) + ' degrees for ' + eval(eval('' + great_circle_distance(spanoone.getAttribute('data-geo').split(',')[0], spanoone.getAttribute('data-geo').split(',')[1], spanotwo.getAttribute('data-geo').split(',')[0], spanotwo.getAttribute('data-geo').split(',')[1])) / 1000.0) + ' kilometers'; //document.getElementById('plots').innerHTML+='
' + divih + '
'; document.getElementById('plots').innerHTML+='
' + divih + '
'; } else { spanotwo.innerHTML='❌'; tcl=' to ' + spanotwo.title + ' '; lastwo=\"//www.google.com/maps/dir/\" + spanoone.getAttribute('data-geo') + \"/\" + spanotwo.getAttribute('data-geo') + \"' + '#' + '\" + 'Leg ' + fcl + tcl + ' heads off at ' + great_circle_bearing(spanoone.getAttribute('data-geo').split(',')[0], spanoone.getAttribute('data-geo').split(',')[1], spanotwo.getAttribute('data-geo').split(',')[0], spanotwo.getAttribute('data-geo').split(',')[1]) + ' degrees for ' + eval(eval('' + great_circle_distance(spanoone.getAttribute('data-geo').split(',')[0], spanoone.getAttribute('data-geo').split(',')[1], spanotwo.getAttribute('data-geo').split(',')[0], spanotwo.getAttribute('data-geo').split(',')[1])) / 1000.0) + ' kilometers'; //document.getElementById('plots').innerHTML+='
' + divih + '
'; document.getElementById('plots').innerHTML+='
' + divih + '
'; } } return true; } function winopit() { if (('' + document.getElementById(gdivid).title) == ('' + document.getElementById(gdivid).title).trim()) { window.open(gw1,gw2,gw3); } document.getElementById(gdivid).title=('' + document.getElementById(gdivid).title).trim(); } function owindowopen(odiv,w1,w2,w3) { if (lastgdivid == '' + odiv.id) { document.getElementById(gdivid).title+=String.fromCharCode(32); document.getElementById(gdivid).style.visibility='hidden'; } else { gdivid='' + odiv.id; lastgdivid=gdivid; gw1=w1; gw2=w2; gw3=w3; setTimeout(winopit, 3000); } } function zifcheck(zwiois) { var waszoom=1; var sparear=null; var xif=-999, yif=-999, xxif=-999, yyif=-999; var xlatdeg=0, xlongdeg=0; var zawconto = (zwiois.contentWindow || zwiois.contentDocument); if (!zawconto && zaconto) { zawconto=zaconto; } //alert(11); var zzawconto=zawconto; if (zawconto != null) { //alert('111 ' + zwiois.src); if (zawconto.document) { zawconto = zawconto.document; } //alert('1111 ' + zawconto.body.innerHTML); if (zawconto.body.innerHTML.indexOf('>') != -1) { var iiizoom=eval(eval('' + ('' + zawconto.getElementById('myimg').style.width).replace('px','')) / 360); //eval('' + zawconto.getzoom()); //alert('' + iiizoom); //alert(eval('' + zawconto.getzoom())); //alert(zawconto.getElementById('myimg').getBoundingClientRect().width); if (lastiizoom != iiizoom) { var isp=0; var huhrect=document.getElementById('ifcountries').getBoundingClientRect(); var ospancount=spancount; newone=eval(1 + spancount); while (document.getElementById('span' + isp)) { if (isp < ospancount) { waszoom=document.getElementById('span' + isp).getAttribute('data-zoom'); if (waszoom != iiizoom) { xlatdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[0]); xlongdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[1]); xxif=eval(iiizoom * eval(180 + eval('' + xlongdeg))); yyif=eval(iiizoom * eval(90 - eval('' + xlatdeg))); if (1 == 1) { document.getElementById('plots').innerHTML+='x'; nodiv(isp, spancount); spancount++; document.getElementById('span' + isp).style.display='none'; } else { document.getElementById('span' + isp).style.top='' + eval(eval('' + huhrect.top) + yyif) + 'px'; document.getElementById('span' + isp).style.left='' + eval(eval('' + huhrect.left) + xxif) + 'px'; document.getElementById('span' + isp).setAttribute('data-zoom', '' + iiizoom); document.getElementById('span' + isp).setAttribute('data-iframepos', '' + huhrect.left + ',' + huhrect.top); document.getElementById('sspan' + isp).innerHTML=document.getElementById('span' + isp).outerHTML; } } } isp++; } lastiizoom=iiizoom; } } } } function geojsonrightclick(ev,iiz,isd) { pos3=-999; pos4=-999; if (ev.touches) { if (ev.touches[0].pageX) { pos3 = ev.touches[0].pageX; pos4 = ev.touches[0].pageY; } else { pos3 = ev.touches[0].clientX; pos4 = ev.touches[0].clientY; } console.log('pos3 = ' + pos3 + ',pos4 = ' + pos4); } else if (ev.clientX || ev.clientY) { pos3 = ev.clientX; pos4 = ev.clientY; console.log('pos3 = ' + pos3 + ' ,pos4 = ' + pos4); } else { pos3 = ev.pageX; pos4 = ev.pageY; console.log('pos3 = ' + pos3 + ', pos4 = ' + pos4); } if (pos3 >= 0 && pos4 >= 0) { if (iiz < lastiizoom) { iiz=lastiizoom; } xlatdeg=eval(90 - eval(eval('' + pos4) / iiz)); xlongdeg=eval(-180 + eval(eval('' + pos3) / iiz)); var huhrect=document.getElementById('ifcountries').getBoundingClientRect(); //alert(' ... second yay! ' + lastiizoom + ' vs ' + iiz + ' ' + ev.clientX + ',' + ev.clientY); if (isdouble == 0) { document.getElementById('plots').innerHTML+=''; storeaway(document.getElementById('span' + spancount)); spancount++; setTimeout(nospan, 30000); isdouble=1; //nolineplease=true; blk='hidden'; setTimeout(isdf, 3000); //alert('Nolineplease'); } else { blk='hidden'; nolineplease=true; //alert('nolineplease'); } } return false; //' ... second yay! ' + lastiizoom + ' vs ' + iiz + ' ' + e.clientX + ',' + e.clientY; } function thisonl() { //alert(21); elem = document.getElementById('mycanvas'); //alert(211); context = elem.getContext('2d'); //alert(2111); setTimeout(canvasize, 5000); //alert(21111); } function ifcheck(ziois) { var ourm=mobaccum; var waszoom=1; var sparear=null, gsparear=null; var xif=-999, yif=-999, xxif=-999, yyif=-999; var zioissrc=ziois.src.split('#')[0]; if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && zaconto != null && locationhash != '') { zaconto=zaconto; zioissrc=ziois.src.split('#')[0] + ('#' + locationhash + '#' + location.hash).replace('##','&').replace('##','&').replace('#','&').replace('#','&'); } else { zaconto = (ziois.contentWindow || ziois.contentDocument); //alert(11); } zzaconto=zaconto; if (zaconto != null) { //alert('111 ' + xiois.src); try { if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { zaconto=zaconto; } else { if (zaconto.document) { zaconto = zaconto.document; zzaconto=zaconto; } } //alert('1111 ' + zaconto.body.innerHTML); //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { // alert(111); //} if (zaconto.body.innerHTML.indexOf('>') != -1) { zoomdone=false; lastiizoom=(zioissrc.indexOf('zoom=') != -1 ? eval(zioissrc.split('zoom=')[1].split('&')[0].split('#')[0]) : lastiizoom); var itwo=''; if (document.getElementById('myp')) { itwo=('' + document.getElementById('myp').getAttribute('data-fc')).replace(/^null/g,'').replace(/^undefined/g,'').trim().toUpperCase(); } if (itwo == '' && lastcode != '') { itwo=lastcode; } //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { // alert(itwo); //} if (eval('' + itwo.length) == 2 || (document.getElementById('placegeo').title + document.getElementById('placegeo').value).trim() != '') { var xlatdeg=0, xlongdeg=0; if ((document.getElementById('placegeo').title + document.getElementById('placegeo').value).indexOf(',') != -1) { xlatdeg=eval('' + (document.getElementById('placegeo').title + document.getElementById('placegeo').value).split(',')[0]); xlongdeg=eval('' + (document.getElementById('placegeo').title + document.getElementById('placegeo').value).split(',')[1]); } if (zioissrc.indexOf('refresh=') != -1 && zioissrc.indexOf('zoom=') != -1) { iizoom=lastiizoom; if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { zaconto=zaconto; // alert('99'); } else if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { zaconto.getElementById('mg').style.visibility='hidden'; //zaconto.getElementById('mg').setAttribute('readonly', true); zaconto.getElementById('mg').style.display='none'; } else { zaconto.getElementById('mg').onmousedown=function(){ lastiizoom=eval(2 * lastiizoom); setTimeout(parent.rifcheck, 3000); return true; }; zaconto.getElementById('mg').ontouchdown=function(){ lastiizoom=eval(2 * lastiizoom); setTimeout(parent.rifcheck, 3000); return true; }; document.body.ontouchend=function(){ alert('heRe'); return true; }; } setTimeout(rifcheck, 2000); //alert('Where'); jjans=jjans.replace(/\ \ \ \ \ $/g,''); if (locationhash == '' && !navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { return true; } } else { iizoom=eval(eval('' + ('' + zaconto.getElementById('myimg').style.width).replace('px','')) / 360); //eval('' + zaconto.getzoom()); } xif=eval(iizoom * eval(180 + eval('' + xlongdeg))); yif=eval(iizoom * eval(90 - eval('' + xlatdeg))); //alert('' + xif + ',' + yif); //alert(itwo); //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { // alert(4987); //} var isp=0; var jsp=0; if (eval('' + itwo.length) == 2) { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { // alert(2); //} if (xif >= -180 && yif >= -90) { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { // alert(zioissrc); //} if (lastiizoom != iizoom || zioissrc.indexOf('refresh=') != -1) { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i) && locationhash != '') { // alert(222); //} var huhrect=document.getElementById('ifcountries').getBoundingClientRect(); //alert('5:' + document.getElementById('ifcountries').offsetLeft + ',' + document.getElementById('ifcountries').offsetTop); var ospancount=spancount; newone=eval(1 + spancount); while (document.getElementById('span' + isp)) { if (isp < ospancount) { waszoom=document.getElementById('span' + isp).getAttribute('data-zoom'); if (waszoom != iizoom) { xlatdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[0]); xlongdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[1]); xxif=eval(iizoom * eval(180 + eval('' + xlongdeg))); yyif=eval(iizoom * eval(90 - eval('' + xlatdeg))); if (1 == 1) { if (4 == 5) { alert(5786); } document.getElementById('plots').innerHTML+='x'; nodiv(isp, spancount); spancount++; jsp++; document.getElementById('span' + isp).style.display='none'; } else { document.getElementById('span' + isp).style.top='' + eval(eval('' + huhrect.top) + yyif) + 'px'; document.getElementById('span' + isp).style.left='' + eval(eval('' + huhrect.left) + xxif) + 'px'; document.getElementById('span' + isp).setAttribute('data-zoom', '' + iizoom); document.getElementById('span' + isp).setAttribute('data-iframepos', '' + huhrect.left + ',' + huhrect.top); document.getElementById('sspan' + isp).innerHTML=document.getElementById('span' + isp).outerHTML; } } } isp++; } } spancount=eval(isp + jsp); var dars=null, kkkfound=false, idars=0; //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { // alert('|' + jjans + '|vs|' + jjans.replace(/\ \ \ \ \ $/g,'') + '|'); //} if (jjans == jjans.replace(/\ \ \ \ \ $/g,'')) { //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { // alert('huhyes|' + jjans + '|'); //} //if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { // alert(14987); //} if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { //document.getElementById('plots').innerHTML+='x'; mobaccum+=''; zaconto.body.innerHTML+=ourm + ''; ourm=''; } else { if (4 == 5) { alert(6786); } document.getElementById('plots').innerHTML+='x'; } spancount++; //if (!navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { setTimeout(nospan, 30000); //} } } sofararealist+=itwo + '|'; var ars=zaconto.getElementsByTagName('area'); for (var iars=0; iars { if (i < elements.length - 1) { zaconto.body.dispatchEvent(new Event(\"click\", { bubbles: true, // only bubbles and cancelable cancelable: true, // work in the Event constructor clientX: xif, clientY: yif })); } }); } else { zaconto.elementFromPoint(xif, yif).click(); } } } } } } catch(hgjgs) { } } jjans=jjans.replace(/\ \ \ \ \ $/g,''); return true; } function nonmifcheck(ziois) { var waszoom=1; var sparear=null, gsparear=null; var xif=-999, yif=-999, xxif=-999, yyif=-999; zaconto = (ziois.contentWindow || ziois.contentDocument); //alert(11); zzaconto=zaconto; if (zaconto != null) { //alert('111 ' + xiois.src); try { if (zaconto.document) { zaconto = zaconto.document; } //alert('1111 ' + zaconto.body.innerHTML); if (zaconto.body.innerHTML.indexOf('>') != -1) { zoomdone=false; lastiizoom=(ziois.src.indexOf('zoom=') != -1 ? eval(ziois.src.split('zoom=')[1].split('&')[0].split('#')[0]) : lastiizoom); var itwo=''; if (twomw != '') { itwo=('' + twomw); } if (itwo == '' && lastcode != '') { itwo=lastcode; } //alert(ziois.src + ' 11111 ' + itwo + ':' + (document.getElementById('placegeo').title + document.getElementById('placegeo').value).trim()); if (eval('' + itwo.length) == 2 || (document.getElementById('placegeo').title + document.getElementById('placegeo').value).trim() != '') { var xlatdeg=0, xlongdeg=0; if ((document.getElementById('placegeo').title + document.getElementById('placegeo').value).indexOf(',') != -1) { xlatdeg=eval('' + (document.getElementById('placegeo').title + document.getElementById('placegeo').value).split(',')[0]); xlongdeg=eval('' + (document.getElementById('placegeo').title + document.getElementById('placegeo').value).split(',')[1]); } if (ziois.src.indexOf('refresh=') != -1 && ziois.src.indexOf('zoom=') != -1) { iizoom=lastiizoom; zaconto.getElementById('mg').onmousedown=function(){ lastiizoom=eval(2 * lastiizoom); setTimeout(parent.rifcheck, 3000); return true; }; zaconto.getElementById('mg').ontouchdown=function(){ lastiizoom=eval(2 * lastiizoom); setTimeout(parent.rifcheck, 3000); return true; }; setTimeout(rifcheck, 2000); //alert('Where'); return true; } else { //alert('2 ' + + ('' + zaconto.getElementById('myimg').width).replace('px','')); iizoom=eval(eval('' + ('' + zaconto.getElementById('myimg').width).replace('px','')) / 360); //eval('' + zaconto.getzoom()); //alert('' + iizoom); } xif=eval(iizoom * eval(180 + eval('' + xlongdeg))); yif=eval(iizoom * eval(90 - eval('' + xlatdeg))); //alert('' + xif + ',' + yif); //alert(itwo + ' ' + jjans + '?'); var isp=0; var jsp=0; if (eval('' + itwo.length) == 2) { if (xif >= -180 && yif >= -90) { if (lastiizoom != iizoom || ziois.src.indexOf('refresh=') != -1) { var huhrect=document.getElementById('ifcountries').getBoundingClientRect(); var ospancount=spancount; newone=eval(1 + spancount); while (document.getElementById('span' + isp)) { if (isp < ospancount) { waszoom=document.getElementById('span' + isp).getAttribute('data-zoom'); if (waszoom != iizoom) { xlatdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[0]); xlongdeg=eval('' + document.getElementById('span' + isp).getAttribute('data-geo').split(',')[1]); xxif=eval(iizoom * eval(180 + eval('' + xlongdeg))); yyif=eval(iizoom * eval(90 - eval('' + xlatdeg))); if (1 == 1) { //alert(786); document.getElementById('plots').innerHTML+='x'; nodiv(isp, spancount); spancount++; jsp++; document.getElementById('span' + isp).style.display='none'; } else { document.getElementById('span' + isp).style.top='' + eval(eval('' + huhrect.top) + yyif) + 'px'; document.getElementById('span' + isp).style.left='' + eval(eval('' + huhrect.left) + xxif) + 'px'; document.getElementById('span' + isp).setAttribute('data-zoom', '' + iizoom); document.getElementById('span' + isp).setAttribute('data-iframepos', '' + huhrect.left + ',' + huhrect.top); document.getElementById('sspan' + isp).innerHTML=document.getElementById('span' + isp).outerHTML; } } } isp++; } } spancount=eval(isp + jsp); //alert(jjans + '?'); if (jjans == jjans.replace(/\ \ \ \ \ $/g,'')) { //alert(2786); document.getElementById('plots').innerHTML+='x'; spancount++; setTimeout(nospan, 30000); } } sofararealist+=itwo + '|'; var ars=zaconto.getElementsByTagName('area'); for (var iars=0; iars { if (i < elements.length - 1) { zaconto.body.dispatchEvent(new Event(\"click\", { bubbles: true, // only bubbles and cancelable cancelable: true, // work in the Event constructor clientX: xif, clientY: yif })); } }); } else { zaconto.elementFromPoint(xif, yif).click(); } } } } } } catch(hgjgs) { } } jjans=jjans.replace(/\ \ \ \ \ $/g,''); return true; } function nodiv(wasid, newid) { var divsoarr=document.getElementsByTagName('div'); for (var idivs=0; idivs newone) { //alert('here2'); setTimeout(function(){ drawlinebetween(spanos[eval(-2 + spanos.length)], spanos[eval(-1 + spanos.length)]); }, 5000); } } else if (('' + divsoarr[idivs].id).indexOf('line_') == 0 && ('' + divsoarr[idivs].id + '~').indexOf('_' + wasid + '~') != -1) { divsoarr[idivs].style.display='none'; spanos.push(document.getElementById('span' + newid)); //alert('there ' + wasid + ' ' + spanos.length + ' ' + newone); if (eval('' + spanos.length) > newone) { //alert('there2'); setTimeout(function(){ drawlinebetween(spanos[eval(-2 + spanos.length)], spanos[eval(-1 + spanos.length)]); }, 5000); } } } } "; exit; } else if (isset($_POST['returnxytoparent']) && isset($_POST['ix']) && isset($_POST['iy'])) { $alp="0123456789ABCDEF"; //=map&chs=600x450& //echo ""; //exit; if (strpos(urldecode($_POST['returnxytoparent']), 'data:') !== false) { //echo ''; //exit; $im = imagecreatefromstring(base64_decode(explode(";base64,", str_replace(' ','+',urldecode($_POST['returnxytoparent'])) )[1])); } else { $imgurl='http://chart.googleapis.com/chart?' . str_replace('=map&chld=', '=map&chs=455x350&chld=', explode('?', str_replace('+',' ',urldecode($_POST['returnxytoparent'])))[1]); //echo ""; //exit; $im = imagecreatefromstring(file_get_contents($imgurl)); } $tlrgb = imagecolorat($im, $_POST['ix'], $_POST['iy']); $topclick=''; if ($tlrgb) { //echo ''; //exit; $tlr = ($tlrgb >> 16) & 0xFF; $tlg = ($tlrgb >> 8) & 0xFF; $tlb = $tlrgb & 0xFF; $blchex=substr(substr($alp,($tlr / 16)),0,1) . substr(substr($alp,($tlr % 16)),0,1) . substr(substr($alp,($tlg / 16)),0,1) . substr(substr($alp,($tlg % 16)),0,1) . substr(substr($alp,($tlb / 16)),0,1) . substr(substr($alp,($tlb % 16)),0,1); $isclick=false; if (strtoupper($blchex) == 'D0D0D0' || strtoupper($blchex) == 'FFFFFF' || strtoupper($blchex) == 'B3BCC0' || strtoupper($blchex) == 'BCBCBC') { exit; } if ($_POST['imode'] == 'mouseover') { if (strpos(strtoupper($_POST['imode']), strtoupper($blchex)) === false && 1 == 1) { exit; } } if (isset($_POST['patparent']) && isset($_POST['imode'])) { $pat=str_replace('+',' ',urldecode($_POST['patparent'])); if ($_POST['imode'] == 'click') { if (strpos(str_replace('+',' ',urldecode($_POST['patparent'])), '#' . strtoupper($blchex)) !== false) { $topclick=" parent.document.getElementById('" . explode('"', explode(' id="', explode('#' . strtoupper($blchex), $pat)[0])[-1 + sizeof(explode(' id="', explode('#' . strtoupper($blchex), $pat)[0]))] )[0] . "').click(); "; } else if (strpos(str_replace('+',' ',urldecode($_POST['patparent'])), '#' . strtolower($blchex)) !== false) { $topclick=" parent.document.getElementById('" . explode('"', explode(' id="', explode('#' . strtolower($blchex), $pat)[0])[-1 + sizeof(explode(' id="', explode('#' . strtolower($blchex), $pat)[0]))] )[0] . "').click(); "; } } else { $topclick=" parent.document.getElementById('ici').title=parent.document.getElementById('" . explode('"', explode(' id="', explode('#' . strtolower($blchex), $pat)[0])[-1 + sizeof(explode(' id="', explode('#' . strtolower($blchex), $pat)[0]))] )[0] . "').title; "; //echo ""; //exit; } } echo ''; } //else { //echo ''; //exit; //} imagedestroy($im); exit; } $setrange=''; $redplace=-1; $redname=''; $thingos=''; if (isset($_GET['match'])) { if (!isset($_GET['ccode'])) { $_GET['ccode']=explode('-',explode(urlencode('-'), $_GET['match'])[0])[0]; if ($_GET['ccode'] == $_GET['match']) { for ($ihuh=0; $ihuhGeoJson World Countries via Google Chart Image Chart Map Chart - RJM Programming - November, 2023
"; } exit; } else if (isset($_GET['ccode']) || isset($_POST['ccode'])) { $mlls=[false,false,false,false]; $nextdone=false; $nexttwodone=false; $nextthreedone=false; $nextfourdone=false; $minlat=-90.0; $minlong=-180.0; $maxlat=90.0; $maxlong=180.0; $rucc=''; $ucc=''; $ruccs=[]; $thish=''; $hasv=''; if (isset($_GET['ccode'])) { $hashv='#' . $_GET['ccode']; $ucc=trim(str_replace('+',' ',urldecode($_GET['ccode']))); $rucc=$ucc; } else if (isset($_POST['ccode'])) { $hashv='#' . $_POST['ccode']; $ucc=trim(str_replace('+',' ',urldecode($_POST['ccode']))); $rucc=$ucc; } if (strpos($ucc, ',') === false) { $hashv=''; $ruccs=[$rucc]; } if (strpos($ucc, ',') !== false) { $uccs=explode(',', $ucc); $ruccs=explode(',', $rucc); $thish="GeoJson World Countries via Google Chart Image Chart Map Chart - RJM Programming - November, 2023 "; for ($iw=0; $iw","", $thish); } } $succ=''; if (isset($_GET['clang']) || isset($_POST['clang'])) { if (isset($_GET['clang'])) { $thish=str_replace('?', '?clang=' . $_GET['clang'] . '&', $thish); $succ=strtolower(trim(str_replace('+',' ',urldecode($_GET['clang'])))) . '.'; } else if (isset($_POST['ccode'])) { $thish=str_replace('?', '?clang=' . $_POST['clang'] . '&', $thish); $succ=strtolower(trim(str_replace('+',' ',urldecode($_POST['clang'])))) . '.'; } if (strlen($succ) != 3) { $succ=''; } } if ($thish != '') { if (isset($_GET['world']) || isset($_POST['world'])) { $thish=str_replace('?', '?world=y&', $thish); } if (isset($_GET['redregionquiz']) || isset($_POST['redregionquiz'])) { $thish=str_replace('?', '?redregionquiz=y&', $thish); } echo $thish; exit; } if (strlen($ucc) == 2) { if (strpos($ourtzlist, ',' . $ucc . ',') !== false) { $preohbit=explode(',' . $ucc . ',', $ourtzlist)[0]; $ohbit=explode('<', $preohbit)[-1 + sizeof(explode('<', $preohbit))]; if (strpos($ohbit, ' title="') !== false) { $tbitis=explode('"', explode(' title="', $ohbit)[1])[0]; if (sizeof(explode(',', $tbitis)) == 4) { $setrange=$tbitis; } } } if (strtoupper($ucc) == 'RU' || strtoupper($ucc) == 'SI') { $b='r'; } $beworried=true; $nine=9; $seven=7; $isbig=1; for ($jk=0; $jk 1) { $kkk=0; for ($kk=0; $kk $maxlong) { $maxlong=min(180.0,($nine + $thislong)); } if ($thislat < $minlat) { $minlat=max(-90.0,(-$seven + $thislat)); } if ($thislat > $maxlat) { $maxlat=min(90.0,($seven + $thislat)); } // echo ' ... ' . $thislong . ' ' . $maxlong; } } } if ($beworried && $nine == 9 && $seven == 7) { $minlong=max(-180.0,(-9 + $minlong)); $maxlong=min(180.0,(9 + $maxlong)); $minlat=max(-90.0,(-7 + $minlat)); $maxlat=min(90.0,(7 + $maxlat)); $ptwo=explode(' data-geo="', $ourtzlist); for ($kkk=1; $kkk $maxlong || $complat < $minlat || $complat > $maxlat) { //if (abs($complong - $minlong) < 7 || abs($complong - $maxlong) < 7 || abs($complat - $minlat) < 7 || abs($complat - $maxlat) < 7) { if (abs($complat - $minlat) < 7 || abs($complat - $maxlat) < 7) { if ($complong < $minlong) { $mlls[0]=true; } if ($complong > $maxlong) { $mlls[1]=true; } if ($complat < $minlat) { $mlls[2]=true; } if ($complat > $maxlat) { $mlls[3]=true; } if (!$nextdone) { if ($complong < $minlong) { $minlong=max(-180.0,(-1 + $complong)); } if ($complong > $maxlong) { $maxlong=min(180.0,(1 + $complong)); } if ($complat < $minlat) { $minlat=max(-90.0,(-1 + $complat)); } if ($complat > $maxlat) { $maxlat=min(90.0,(1 + $complat)); } $nextdone=true; } else if (!$nexttwodone) { if ($complong < $minlong) { $minlong=max(-180.0,(-1 + $complong)); } if ($complong > $maxlong) { $maxlong=min(180.0,(1 + $complong)); } if ($complat < $minlat) { $minlat=max(-90.0,(-1 + $complat)); } if ($complat > $maxlat) { $maxlat=min(90.0,(1 + $complat)); } $nexttwodone=true; } else if (!$nextthreedone) { if ($complong < $minlong) { $minlong=max(-180.0,(-1 + $complong)); } if ($complong > $maxlong) { $maxlong=min(180.0,(1 + $complong)); } if ($complat < $minlat) { $minlat=max(-90.0,(-1 + $complat)); } if ($complat > $maxlat) { $maxlat=min(90.0,(1 + $complat)); } $nextthreedone=true; } else if (!$nextfourdone) { if ($complong < $minlong) { $minlong=max(-180.0,(-1 + $complong)); } if ($complong > $maxlong) { $maxlong=min(180.0,(1 + $complong)); } if ($complat < $minlat) { $minlat=max(-90.0,(-1 + $complat)); } if ($complat > $maxlat) { $maxlat=min(90.0,(1 + $complat)); } if ($mlls[0] && $mlls[1] && $mlls[2] && $mlls[3]) { $nextfourdone=true; } } } } } } } } } if ($setrange != '' && !isset($_GET['world']) && !isset($_POST['world'])) { $url='http://chart.googleapis.com/chart?cht=map:fixed=' . $setrange . '&chs=600x350&chld=&chco=&chdl='; } else { $url='http://chart.googleapis.com/chart?cht=map:fixed=' . $minlat . ',' . $minlong . ',' . $maxlat . ',' . $maxlong . '&chs=600x350&chld=&chco=&chdl='; } $zero=explode(strtoupper($ucc) . '-', $iccs)[0]; $subi=explode('', substr($iccs, (-3 + strlen($zero))))[0]; //$subi=explode('', explode('', $subi); $ru=-1; $rl=-1; if (isset($_GET['redregionquiz']) || isset($_POST['redregionquiz']) || strpos(('' . $_SERVER['QUERY_STRING']), 'redregionquiz') !== false) { for ($ir=0; $ir= 0 && $ru >= 1) { $redplace=max(1,rand($rl, $ru)); } } $sr=-1; for ($ir=0; $ir', $therest); $thisstate=''; //echo $therest; //exit; for ($jr=0; $jr', $therestbits[$jr])[(-1 + sizeof(explode('>', $therestbits[$jr])))])); //if ($thistext != '') { //echo $thiscode . $therest . ' ThistexT=' . $thistext; //exit; //} if ($thisstate == '' && $thistext != $thiscode && trim(str_replace(' ','',$thistext)) != '' && substr(substr(($thistext . ' '),2),0,1) != '-') { //if ($thistext != '') { //echo 'Thistext=' . $thistext; //exit; //} $thisstate=str_replace(' ','',$thistext); } if (isset($_GET['match'])) { if ($thiscode == urldecode($_GET['match']) && $thisstate != '') { for ($ihuh=0; $ihuh', $iccs)[0]))])[0]; $interimurl='http://' . $succ . 'wikipedia.org' . $relurl; $geostuff=file_get_contents($interimurl); //file_put_contents('x.x', $interimurl . "\n" . $geostuff); if (strpos($geostuff, ' class="latitude">') !== false) { $xxlat=explode('<', explode(' class="latitude">', $geostuff)[1])[0]; //echo " lat is " . $xxlat; if (strpos($xxlat, 'S') !== false) { $thislat=(-1.0 * explode("°", $xxlat)[0]); } else { $thislat=(1.0 * explode("°", $xxlat)[0]); } //echo " Lat is " . $thislat; $xxlong=explode('<', explode(' class="longitude">', $geostuff)[1])[0]; //echo " long is " . $xxlong; if (strpos($xxlong, 'E') !== false) { $thislong=(-1.0 * explode("°", $xxlong)[0]); } else { $thislong=(1.0 * explode("°", $xxlong)[0]); } //echo " Long is " . $thislong; //exit; if ($thislong < $minlong) { $minlong=max(-180.0,(-1 + $thislong)); } if ($thislong > $maxlong) { $maxlong=min(180.0,(1 + $thislong)); } if ($thislat < $minlat) { $minlat=max(-90.0,(-1 + $thislat)); } if ($thislat > $maxlat) { $maxlat=min(90.0,(1 + $thislat)); } //echo " minLong is " . $minlong; //echo " minLat is " . $minlat; //echo " maxLong is " . $maxlong; //echo " maxLat is " . $maxlat; //echo substr(explode(' class="latitude">', $geostuff)[1],0,40); //exit; } } $sixrand=$sixrs[rand(0, (-1 + sizeof($sixrs)))]; for ($kr=1; $kr<6; $kr++) { $sixrand.=$sixrs[rand(0, (-1 + sizeof($sixrs)))]; } if ($statecount != 0 && ($ir >= (-1 + $redplace))) { // || $sr >= (-1 + $redplace)) && $statecount != 0) { if ($redname == '') { $redname=$thisstate; $sixrand='ff0000'; } else if ($sixrand == 'ff0000' && $redplace >= 0) { $sixrand='ff7712'; } else if (substr($sixrand,0,1) == 'f' && $redplace >= 0) { $sixrand='e' . substr($sixrand,1); } } else if ($sixrand == 'ff0000' && $redplace >= 0) { $sixrand='ff7712'; } else if (substr($sixrand,0,1) == 'f' && $redplace >= 0) { $sixrand='e' . substr($sixrand,1); } else { //echo $sixrand; //exit; $sixrand=str_replace('00ff00','22ff22',str_replace('ff0000','ff2222',str_replace('0000ff','2222ff',$sixrand))); while (strpos($url, $sixrand) !== false) { $sixrand=$sixrs[rand(0, (-1 + sizeof($sixrs)))]; for ($kr=1; $kr<6; $kr++) { $sixrand.=$sixrs[rand(0, (-1 + sizeof($sixrs)))]; } $sixrand=str_replace('00ff00','22ff22',str_replace('ff0000','ff2222',str_replace('0000ff','2222ff',$sixrand))); } } if ($statecount == 0) { if (!isset($_GET['world']) && !isset($_POST['world'])) { if ($rucc != strtoupper($ucc) && $rucc != strtolower($ucc)) { if (strpos($ourtzlist, ',' . strtoupper(substr($thiscode,0,2)) . ',') !== false) { $contbit=explode('/', explode('>', explode(',' . strtoupper(substr($thiscode,0,2)) . ',', $ourtzlist)[1])[1])[0]; if (strpos($continfo, ';' . $contbit . ';') === false) { $contbit=''; } } } } if ($maxlat > 70.0) { $maxlat=80.0; } if ($setrange != '' && !isset($_GET['world']) && !isset($_POST['world'])) { $url='http://chart.googleapis.com/chart?' . $tbit . 'cht=map:fixed=' . $setrange . '&chdlp=' . $b . '&chs=600x450&chld=' . $thiscode . '&chco=' . '00ff00' . '|' . $sixrand . '&chdls=' . '00ff00' . '|' . $sixrand . ',6&chdl=' . urlencode($thisstate); } else { $url='http://chart.googleapis.com/chart?' . $tbit . 'cht=map:fixed=' . $minlat . ',' . $minlong . ',' . $maxlat . ',' . $maxlong . '&chdlp=' . $b . '&chs=600x450&chld=' . $thiscode . '&chco=' . '00ff00' . '|' . $sixrand . '&chdls=' . '00ff00' . '|' . $sixrand . ',6&chdl=' . urlencode($thisstate); } //echo $url; //exit; } else { if ($contbit != '') { if (strpos($ourtzlist, ',' . strtoupper(substr($thiscode,0,2)) . ',') !== false) { if ($contbit != explode('/', explode('>', explode(',' . strtoupper(substr($thiscode,0,2)) . ',', $ourtzlist)[1])[1])[0]) { $contbit=''; } } } if (isset($_GET['match'])) { if ($thiscode == urldecode($_GET['match']) && $thisstate != '') { for ($ihuh=0; $ihuh= 6) { if (substr($_GET['chco'],0,1) == '|') { $_GET['chco']=substr($_GET['chco'],1); } else if (substr($_GET['chco'],0,3) == urlencode('|')) { $_GET['chco']=substr($_GET['chco'],3); } $sixrand=substr($_GET['chco'],0,6); $_GET['chco']=substr($_GET['chco'],6); } } $url.='|' . urlencode($thisstate); $url=str_replace('&chco=', '|' . $thiscode . '&chco=', $url); $url=str_replace('&chdls=', '|' . $sixrand . '&chdls=', $url); $url=str_replace('&chdl=', '|' . $sixrand . ',6&chdl=', $url); //echo $url; //exit; } $statecount++; } //else { //echo "oops"; //exit; //} } } $url=str_replace('&chco=', '|' . explode('-', $thiscode)[0] . '&chco=', $url); $url=str_replace('&chdls=', '|' . '0000ff' . '&chdls=', $url); $url=str_replace('&chdl=', '|' . '0000ff' . ',6&chdl=', $url); if (isset($_GET['redregionquiz']) || isset($_POST['redregionquiz']) || strpos(('' . $_SERVER['QUERY_STRING']), 'redregionquiz') !== false) { //if ($redname != '' && // (isset($_GET['cellnumber']) || isset($_POST['cellnumber']) && // (isset($_GET['chosencell']) || isset($_POST['chosencell'])) { if ($redname != '' && strpos($url, 'chco=') !== false && strpos($url, 'chdl=') !== false && strpos($url, 'ff0000') !== false) { $cols=explode('|', explode('&', explode('chco=', $url)[1])[0]); $regs=explode('|', explode('&', explode('chdl=', $url)[1])[0]); // http://chart.googleapis.com/chart?chtt=States+and+territories+of+Australia //&cht=map:fixed=-61.5,106.85,-5.46667,162.03333&chdlp=b&chs=600x450 //&chld=AU-NSW|AU-QLD|AU-SA|AU-TAS|AU-VIC|AU-WA|AU-ACT|AU-NT //&chco=74e311|3076e2|ff0000|e73dff|00c34f|02e46b|533845|d62b4a //&chdls=74e311,6|3076e2,6|ff0000,6|e73dff,6|00c34f,6|02e46b,6|533845,6|d62b4a,6 //&chdl=New+South+Wales|Queensland|South+Australia|Tasmania|Victoria|Western+Australia|Australian+Capital+Territory|Northern+Territory for ($icols=0; $icols'); } else if ($redname != '' && isset($_GET['countryname'])) { file_put_contents('lasturlis.html', ''); } else if ($redname != '' && 1 == 5) { file_put_contents('lasturlis.html', ''); } if (1 == 1) { $wasurl=$url; $bas=explode('&', $url); for ($ibas=1; $ibas 1) { $url=str_replace('map:' . explode('&chs=', explode('map:', $url)[1])[0], 'map:fixed=' . explode(':', $hashbit)[1], $url); } else { $url=str_replace('map:' . explode('&chs=', explode('map:', $url)[1])[0], 'map', $url); } } $contbit=explode(':', explode('#;' . $contbit . ';', $hashbit)[1])[0]; //$url=str_replace('&chco=', '&chco=b1bbc1|b1bbc1|', explode('&chdls=', $url)[0]); $chcobit='|00ff00|00ff00'; // http://chart.googleapis.com/chart?chtt=States+and+territories+of+Australia&cht=map:fixed=-61.5,106.85,-5.46667,162.03333&chdlp=b&chs=600x450&chld=AU-NSW|AU-QLD|AU-SA|AU-TAS|AU-VIC|AU-WA|AU-ACT|AU-NT|AU&chco=00ff00|af4269|ff0000|18c26d|e471ae|336c99|24c49c|ebceb5|3e0122|0000ff&chdls=00ff00|af4269,6|ff0000,6|18c26d,6|e471ae,6|336c99,6|24c49c,6|ebceb5,6|3e0122,6|0000ff,6&chdl=New+South+Wales|Queensland|South+Australia|Tasmania|Victoria|Western+Australia|Australian+Capital+Territory|Northern+Territory if (strpos($url, '&chld=') !== false) { $newcontbit=''; $newchcobit=''; $newcs=explode('|', $contbit); for ($inewcs=0; $inewcs"; exit; } //$url=str_replace('http://chart.googleapis.com/chart', 'http://www.rjmprogramming.com.au/ITblog/600/350/', $url); //echo $url; //exit; } } } if (isset($_GET['justfishing']) || isset($_POST['justfishing'])) { echo '' . $url . ''; exit; } if ($url != '') { header('Content-Type: image/png'); echo file_get_contents($url); exit; } else if (1 == 1) { echo " Interfacer to Google Charts Image Chart Map Chart for Regional Country Colour Coding - RJM Programming - November, 2023

Google Charts Image Chart Map Chart Interfacer

RJM Programming - November, 2023

700) { this.method='POST'; if (lastinid == 'bsfour') { this.action=this.action.replace('image_chart.php','rangegeo.php'); document.getElementById('justthat').name='justthat'; } else { this.action=this.action.replace('rangegeo.php','image_chart.php'); document.getElementById('justthat').name='x'; } } else { this.action=this.action.replace('rangegeo.php','image_chart.php'); this.method='GET'; if (document.getElementById('justthat').outerHTML.indexOf(' name=') != -1) { document.getElementById('justthat').name='x'; } } document.getElementById('jfrepos').style.display='block'; document.getElementById('kfrepos').style.display='block'; document.getElementById('ifrepos').style.display='block'; document.getElementById('geochart').style.display='block'; document.getElementById('mapchart').style.display='block'; gcdo(ssv.toUpperCase()); document.getElementById('ccode').value=ssv; return thatcouldbe(true);\" target=ifrepos method=GET action=./image_chart.php> or
 

   




" . ' '; } else { header('Content-Type: image/png'); echo file_get_contents('http://chart.googleapis.com/chart?cht=map:fixed=-60,0,80,-35&chs=600x350&chld=CA-BC|CN|IT|GR|US-UT&chdl=Vancouver|Beijing|Torino|Athens|Salt+Lake+City&chco=B3BCC0|5781AE|FF0000|FFC726|885E80|518274&chtt=Last+Five+Olympic+Hosts&chm=f2010+Winter,000000,0,0,10f2008+Summer,000000,0,1,10f2008+Winter,000000,0,2,10,1,:-5:10f2004+Summer,000000,0,3,10f2004+Summer,000000,0,4,10&chma=0,110,0,0'); } exit; ?>