<html>
<head>
<title>Big Number (Starts at 1/1/1970) Date and Time Guessing via Seconds Since Game - RJM Programming - March, 2022</title>
<style>
input:not([type=button]) { width:10%; background-color:#f0f0f0; }
input[type=button] { background-color:yellow; }
button { background-color:yellow; }
select { background-color:#f0f0f0; }
.spananswer { color: blue; }
.goes { color: purple; }
</style>
<script type='text/javascript'>
var numplayers=location.search.split('numplayers=')[1] ? eval(decodeURIComponent(location.search.split('numplayers=')[1].split('&')[0])) : 1;
var restdone=true;
if (numplayers > 1) { restdone=false; }
var zero=0;
var thecurrentone='';
var im=0;
var playernum='';
var bignum='';
var ansis='';
var pl='';
var sc='';
var zhr=null;
var zform=null;
var iflist=['','','','','','','','',''];
var dow=['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'];
var dowm=['January','February','March','April','May','June','July','August','September','October','November','December'];
var nts=1970;
var adate = null;
var bdate = null;
var his, mis, sis, daym, monthm, yearm;
var now = new Date();
nts=eval('' + now.getFullYear());
var utcMilllisecondsSinceEpoch = now.getTime() - (now.getTimezoneOffset() * 60 * 1000);
var utcSecondsSinceEpoch = Math.round(utcMilllisecondsSinceEpoch / 1000);
var tzo=(' +' + eval(eval('' + now.getTimezoneOffset()) / 60)).replace('+-', '-');
var score=[(location.search.split('pl=')[1] ? eval(decodeURIComponent(location.search.split('pl=')[1].split('&')[0])) : eval(73000 * 24 * 60 * 60))];
var goes=[(location.search.split('sc=')[1] ? eval(decodeURIComponent(location.search.split('sc=')[1].split('&')[0])) : 0)];
var tz=['GMT'];
var emailee=[''];
var butb=['Check my Datetime Above'];
var uselong=[true];
var blurb='';
var eoff='';
var soff='';
var ccellone='';
var myr=[eval(Math.floor(Math.random() * 56) + 1)];
nts++;
for (im=0; im<myr[0]; im++) {
nts++;
utcSecondsSinceEpoch+=eval(24 * 60 * 60);
}
var myantiguess=[(location.search.split('bignum=')[1] ? eval(decodeURIComponent(location.search.split('bignum=')[1].split('&')[0])) : eval(Math.floor(Math.random() * utcSecondsSinceEpoch) + 0))];
for (im=1; im<numplayers; im++) {
score.push(eval(73000 * 24 * 60 * 60));
goes.push(0);
myr.push(myr[0]);
tz.push(tz[0]);
uselong.push(uselong[0]);
butb.push(butb[0]);
emailee.push(emailee[0]);
myantiguess.push(eval(Math.floor(Math.random() * utcSecondsSinceEpoch) + 0));
}
var reducedval=-1;
var reducedvalblurb='';
var tzn=('' + Intl.DateTimeFormat().resolvedOptions().timeZone).replace(/^undefined$/g,'').replace(/^null$/g,'')
function divnit(ki) {
var rtv='';
if (document.getElementById('divn' + ki)) {
rtv=(document.getElementById('divn' + ki).innerText || document.getElementById('divn' + ki).contentWindow || document.getElementById('divn' + ki).contentDocument).trim();
}
rtv+=':';
return rtv.replace(/^\:/g, 'Player ' + ki + ':');
}
function retsg() {
retvl=String.fromCharCode(10) + String.fromCharCode(10) + ' Name:Points left/Survival count for ' + score.length + ' players ... ';
for (var ik=0; ik<score.length; ik++) {
retvl+=' ' + divnit(eval(1 + ik)) + score[ik] + '/' + goes[ik];
}
retvl+=String.fromCharCode(10) + String.fromCharCode(10);
return retvl;
}
function display() {
document.getElementById('score' + thecurrentone).innerHTML='' + score[zero];
document.getElementById('goes' + thecurrentone).innerHTML='' + goes[zero];
//alert('' + myantiguess);
document.getElementById('spananswer' + thecurrentone).innerHTML='' + myantiguess[zero];
adate=new Date(eval(eval('' + myantiguess[zero]) * 1000));
yearm=eval('' + adate.getFullYear());
monthm=dowm[eval(0 + eval('' + adate.getMonth()))];
daym=eval(0 + eval('' + adate.getDate()));
his=eval('' + adate.getHours());
mis=eval('' + adate.getMinutes());
sis=eval('' + adate.getSeconds());
//blurb='';
//document.getElementById('asp').title='';
if (!restdone) { restdone=true; dorest(); }
}
function dorest() {
eoff=document.getElementById('emailoff').href;
soff=document.getElementById('smsoff').href;
ccellone=document.getElementById('cell1').innerHTML;
var acellarr=ccellone.split(' id="');
var newtdis=acellarr[0];
document.getElementById('mythead').innerHTML+='<tr id=row0><th><div id=divn onblur=emailtalk(this); title="Will accept email or SMS dialogue eg. Robert J Metcalfe[rmetcalfe15@gmail.com]" contenteditable=true>Player 1</div></th></tr>';
for (var ii=2; ii<=numplayers; ii++) {
for (var jj=1; jj<acellarr.length; jj++) {
newtdis+=' id="' + acellarr[jj].split('"')[0] + ii + acellarr[jj].replace(acellarr[jj].split('"')[0], '');
}
document.getElementById('mythead').innerHTML=document.getElementById('mythead').innerHTML.replace('</tr>','<th><div id=divn' + ii + ' onblur=emailtalk(this); title="Will accept email dialogue eg. Robert J Metcalfe[rmetcalfe15@gmail.com]" contenteditable=true>Player ' + ii + '</div></th></tr>');
document.getElementById('row1').innerHTML+='<td id=cell' + ii + '>' + newtdis.replace(' value=""', ' value="' + ii + '"') + '</td>';
document.getElementById('spananswer' + ii).innerHTML='' + myantiguess[eval(-1 + ii)];
newtdis=acellarr[0];
}
}
function reduce(invl) {
var retval=0, ij=0;
var cinvl='' + invl;
var xcinvl='';
for (ij=0; ij<cinvl.length; ij++) {
if (cinvl.substring(ij).substring(0,1) != '-') {
retval+=eval(cinvl.substring(ij).substring(0,1));
}
}
xcinvl='' + retval;
while (xcinvl.length > 1) {
retval=0;
for (ij=0; ij<xcinvl.length; ij++) {
if (xcinvl.substring(ij).substring(0,1) != '-') {
retval+=eval(xcinvl.substring(ij).substring(0,1));
}
}
xcinvl='' + retval;
}
reducedval=retval;
reducedvalblurb=' If date you entered represents a birthdate(time) (GMT?) please know the ' + invl + ' numerical date equivalent reduces to a ' + reducedval + ' lucky number for that person. ';
return retval;
}
function checkanswer(buto) {
zero=0;
thecurrentone=('' + buto.id).replace('mybut','');
if (thecurrentone != '') { zero=eval(-1 + eval('' + thecurrentone)); }
if (emailee[zero].trim() != '' && (emailee[zero].indexOf('@') != -1 || emailee[zero].replace(/0/g,'').replace(/1/g,'').replace(/2/g,'').replace(/3/g,'').replace(/4/g,'').replace(/5/g,'').replace(/6/g,'').replace(/7/g,'').replace(/8/g,'').replace(/9/g,'') == '') && buto.innerHTML.indexOf('Awaiting ') == -1) {
if (emailee[zero].indexOf('@') != -1) {
buto.innerHTML='Check my Datetime Above ... <br>Awaiting Email ' + emailee[zero] + ' Reply';
} else {
buto.innerHTML='Check my Datetime Above ... <br>Awaiting SMS ' + emailee[zero] + ' Reply';
}
if (document.URL.indexOf('localhost') != -1 || 1 == 1) {
//alert(document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerHTML.replace(':block',':none').replace(':NONE',':block').split('<form ')[1]);
if (emailee[zero].indexOf('@') != -1) {
document.getElementById('emailoff').href=eoff.replace('mailto:?', 'mailto:' + emailee[zero] + '?').replace('subject=&', 'subject=' + ('1' + thecurrentone).slice(-1) + '&') + encodeURIComponent('Hello ' + divnit(eval(('1' + thecurrentone).slice(-1))).replace(/\:$/g,'') + '. Please reply ( or be prompted and asked via ' + document.URL.split('#')[0].split('?')[0] + '?player=' + ('1' + thecurrentone).slice(-1) + '&bignum=' + document.getElementById('spananswer' + thecurrentone).innerHTML + '&pl=' + document.getElementById('score' + thecurrentone).innerHTML + '&sc=' + document.getElementById('goes' + thecurrentone).innerHTML + '&answer=# ) to the Big Number Game request via RJM Programming by replacing dd/mm/yyyy hh:mi:ss here by your date guess regarding equivalence to big number (seconds since 1/1/1970 GMT) below ... ' + String.fromCharCode(10) + String.fromCharCode(10) + retsg() + String.fromCharCode(10) + (document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerText || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentWindow || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentDocument));
document.getElementById('emailoff').click();
if (('' + goes[zero]) != '0') { alert('Sent off email for ' + (document.getElementById('divn' + ii).innerText || document.getElementById('divn' + ii).contentWindow || document.getElementById('divn' + ii).contentDocument)); }
} else {
document.getElementById('smsoff').href=soff.replace('sms:&', 'sms:' + emailee[zero] + '&').replace('subject=&', 'subject=' + ('1' + thecurrentone).slice(-1) + '&') + encodeURIComponent(('Hello ' + divnit(eval(('1' + thecurrentone).slice(-1))).replace(/\:$/g,'') + '. Please reply ( or be prompted and asked via ' + document.URL.split('#')[0].split('?')[0] + '?player=' + ('1' + thecurrentone).slice(-1) + '&bignum=' + document.getElementById('spananswer' + thecurrentone).innerHTML + '&pl=' + document.getElementById('score' + thecurrentone).innerHTML + '&sc=' + document.getElementById('goes' + thecurrentone).innerHTML + '&answer=# ) to the Big Number Game request via RJM Programming by replacing dd/mm/yyyy hh:mi:ss here by your date guess regarding equivalence to big number (seconds since 1/1/1970 GMT) below ... ' + String.fromCharCode(10) + String.fromCharCode(10) + retsg() + String.fromCharCode(10) + (document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerText || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentWindow || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentDocument)).split(' else lose points')[0] + ' else lose points');
document.getElementById('smsoff').click();
if (('' + goes[zero]) != '0') { alert('Sent off SMS for ' + (document.getElementById('divn' + ii).innerText || document.getElementById('divn' + ii).contentWindow || document.getElementById('divn' + ii).contentDocument)); }
}
} else {
zhr = new XMLHttpRequest();
zform=new FormData();
zform.append('inline', '');
zform.append('from', 'info@rjmprogramming.com.au');
zform.append('to', emailee[zero]);
zform.append('subject', 'Big Number (Starts at 1/1/1970) Date and Time Guessing via Seconds Since Game - RJM Programming - March, 2022');
//alert(emailee[zero] + ' ... ' + document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerHTML.replace(':block',':none').replace(':NONE',':block').split('<form ')[1]);
zform.append('htmlis', ('<body>' + document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerHTML.replace(':block',':none').replace(':NONE',':block') + '</body>'));
//zform.append('htmlis', ('<body><p>test</p></body>')); // + document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerHTML.replace(':block',':none').replace(':NONE',':block') + '</body>'));
zhr.open('post', '//www.rjmprogramming.com.au/HTMLCSS/emailhtml.php', true);
zhr.send(zform);
}
} else {
adate=new Date(eval(eval('' + myantiguess[zero]) * 1000));
yearm=eval('' + adate.getFullYear());
monthm=dowm[eval(0 + eval('' + adate.getMonth()))];
daym=eval(0 + eval('' + adate.getDate()));
his=eval('' + adate.getHours());
mis=eval('' + adate.getMinutes());
sis=eval('' + adate.getSeconds());
document.getElementById('asp').title='Best answer to ' + myantiguess[zero] + ' seconds since 1/1/1970 was what date';
var bdate = new Date(document.getElementById('syear' + thecurrentone).value, eval(-1 + eval('' + document.getElementById('smonth' + thecurrentone).value)), document.getElementById('sday' + thecurrentone).value, document.getElementById('shour' + thecurrentone).value, document.getElementById('sminute' + thecurrentone).value, document.getElementById('ssecond' + thecurrentone).value);
var butcMilllisecondsSinceEpoch = bdate.getTime(); // - (bdate.getTimezoneOffset() * 60 * 1000); // + (bdate.getTimezoneOffset() * 60 * 1000);
if (tz[zero] == 'GMT') {
butcMilllisecondsSinceEpoch-=(bdate.getTimezoneOffset() * 60 * 1000);
}
reduce(butcMilllisecondsSinceEpoch);
var butcSecondsSinceEpoch = Math.round(butcMilllisecondsSinceEpoch / 1000);
blurb = 'Perfect last answer for ' + myantiguess[zero] + ' was ' + ('0' + daym).slice(-2) + '/' + monthm + '/' + yearm + ' ' + ('0' + his).slice(-2) + ':' + ('0' + mis).slice(-2) + ':' + ('0' + sis).slice(-2) + ' GMT whereas you lost ' + Math.abs(eval(eval(butcSecondsSinceEpoch) - eval(myantiguess[zero]))) + ' points with your answer. ' + reducedvalblurb.replace('numerical date', 'numerical ' + document.getElementById('sday' + thecurrentone).value + '/' + dowm[eval(-1 + eval('' + document.getElementById('smonth' + thecurrentone).value))] + '/' + document.getElementById('syear' + thecurrentone).value + ' ' + document.getElementById('shour' + thecurrentone).value + ':' + document.getElementById('sminute' + thecurrentone).value + ':' + document.getElementById('ssecond' + thecurrentone).value + ' ' + document.getElementById('sgmt' + thecurrentone).innerHTML + ' date');
if (('' + score[zero]).indexOf('-') == -1) {
goes[zero]++;
} else if (eval('' + goes[zero]) >= 0.0000001) {
goes[zero]-=0.0000001;
} else {
goes[zero]+=0.0000001;
}
score[zero]-=Math.abs(eval(eval(butcSecondsSinceEpoch) - eval(myantiguess[zero])));
document.getElementById('score' + thecurrentone).innerHTML='' + score[zero];
document.getElementById('goes' + thecurrentone).innerHTML='' + goes[zero];
document.getElementById('mybut' + thecurrentone).value=butb[zero];
if (emailee[zero].indexOf('@') != -1 && buto.innerHTML.indexOf('Awaiting ') != -1) {
if ((document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerText || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentWindow || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentDocument).indexOf('Seconds since 1/1/1970') != -1) {
butb[zero]='';
}
if (emailee[zero].indexOf('@') != -1) {
document.getElementById('emailoff').href=eoff.replace('mailto:?', 'mailto:' + emailee[zero] + '?').replace('subject=&', 'subject=' + ('1' + thecurrentone).slice(-1) + '%20&') + encodeURIComponent('Hello ' + divnit(eval(('1' + thecurrentone).slice(-1))).replace(/\:$/g,'') + '. Results from your last guess are shown below ... ' + String.fromCharCode(10) + String.fromCharCode(10) + blurb + retsg() + String.fromCharCode(10) + String.fromCharCode(10) + (document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerText || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentWindow || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentDocument).replace('Seconds since 1/1/1970', String.fromCharCode(10) + String.fromCharCode(10) + 'Please feel free to reply ( or be prompted and asked via ' + document.URL.split('#')[0].split('?')[0] + '?player=' + ('1' + thecurrentone).slice(-1) + '&pl=' + document.getElementById('score' + thecurrentone).innerHTML + '&sc=' + document.getElementById('goes' + thecurrentone).innerHTML + '&bignum=' + document.getElementById('spananswer' + thecurrentone).innerHTML + '&answer=# ) to the new Big Number Game request via RJM Programming by replacing dd/mm/yyyy hh:mi:ss here by your date guess regarding equivalence to big number (seconds since 1/1/1970 GMT) below ... ' + String.fromCharCode(10) + String.fromCharCode(10) + 'Seconds since 1/1/1970'));
document.getElementById('emailoff').click();
if (('' + goes[zero]) != '0') { alert('Sent off email for ' + (document.getElementById('divn' + ii).innerText || document.getElementById('divn' + ii).contentWindow || document.getElementById('divn' + ii).contentDocument)); }
} else {
document.getElementById('smsoff').href=soff.replace('sms:&', 'sms:' + emailee[zero] + '&').replace('subject=&', 'subject=' + ('1' + thecurrentone).slice(-1) + '&') + encodeURIComponent(('Hello ' + divnit(eval(('1' + thecurrentone).slice(-1))).replace(/\:$/g,'') + '. Please reply ( or be prompted and asked via ' + document.URL.split('#')[0].split('?')[0] + '?player=' + ('1' + thecurrentone).slice(-1) + '&bignum=' + document.getElementById('spananswer' + thecurrentone).innerHTML + '&pl=' + document.getElementById('score' + thecurrentone).innerHTML + '&sc=' + document.getElementById('goes' + thecurrentone).innerHTML + '&answer=# ) to the Big Number Game request via RJM Programming by replacing dd/mm/yyyy hh:mi:ss here by your date guess regarding equivalence to big number (seconds since 1/1/1970 GMT) below ... ' + String.fromCharCode(10) + String.fromCharCode(10) + retsg() + String.fromCharCode(10) + (document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).innerText || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentWindow || document.getElementById('cell' + ('1' + thecurrentone).slice(-1)).contentDocument)).split(' else lose points')[0] + ' else lose points');
document.getElementById('smsoff').click();
if (('' + goes[zero]) != '0') { alert('Sent off SMS for ' + (document.getElementById('divn' + ii).innerText || document.getElementById('divn' + ii).contentWindow || document.getElementById('divn' + ii).contentDocument)); }
}
}
if (butb[zero] != '') {
buto.innerHTML=butb[zero];
}
if (document.getElementById('score' + thecurrentone).innerHTML.replace(/^0$/g,'-1').indexOf('-') != -1) {
if (numplayers == 1) {
alert('You survived until go number ' + goes[zero]);
location.href=document.URL;
}
} else {
myantiguess[zero]=eval(Math.floor(Math.random() * utcSecondsSinceEpoch) + 0);
//if (iflist[zero] != '') { iflist[zero]='' + myantiguess[zero]; }
display();
}
}
}
function showperfect() {
if (blurb != '') {
alert(blurb);
}
}
function fixitzero(iniis, imin, imax) {
var minustwo=-2;
var premin='0';
if (('' + imin).length == 4) {
minustwo=-4;
premin='';
}
if (iniis.value.length == 1) {
if ((premin + iniis.value) >= (premin + imin).slice(minustwo) && (premin + iniis.value) <= (premin + imax).slice(minustwo)) {
iniis.value=premin + iniis.value;
} else {
iniis.value=(premin + imin).slice(-4);
}
} else if (iniis.value.length == eval(0 - eval('' + minustwo))) {
if (('' + iniis.value) >= (premin + imin).slice(minustwo) && ('' + iniis.value) <= (premin + imax).slice(minustwo)) {
iniis.value='' + iniis.value;
} else {
iniis.value=(premin + imin).slice(-4);
}
} else {
iniis.value=(premin + imin).slice(-4);
}
}
function startcalculatory(spano) {
zero=0;
thecurrentone=('' + spano.id).replace('spananswer','');
if (thecurrentone != '') { zero=eval(-1 + eval('' + thecurrentone)); }
document.getElementById('icalculator' + thecurrentone).style.display='block';
document.getElementById('icalculator' + thecurrentone).src=document.getElementById('icalculator' + thecurrentone).src.split('#')[0].split('?')[0] + '?clientfirstnum=' + spano.innerHTML + '&clientoper=' + encodeURIComponent('/') + '&clientsecnum=' + eval(24 * 60 * 60 * 365.25) + '.0#firstnum';
}
function startcalculatord(spano) {
zero=0;
thecurrentone=('' + spano.id).replace('spananswer','');
if (thecurrentone != '') { zero=eval(-1 + eval('' + thecurrentone)); }
document.getElementById('icalculator' + thecurrentone).style.display='block';
document.getElementById('icalculator' + thecurrentone).src=document.getElementById('icalculator' + thecurrentone).src.split('#')[0].split('?')[0] + '?clientfirstnum=' + spano.innerHTML + '&clientoper=' + encodeURIComponent('/') + '&clientsecnum=' + eval(24 * 60 * 60) + '.0#firstnum';
}
function tzit(selo) {
zero=0;
thecurrentone=('' + selo.id).replace('seltz','');
if (thecurrentone != '') { zero=eval(-1 + eval('' + thecurrentone)); }
tz[zero]='' + selo.value;
if (selo.value == 'GMT') {
document.getElementById('sgmt' + thecurrentone).innerHTML=selo.value;
document.getElementById('tspec' + thecurrentone).innerHTML='';
} else {
if (tzn != '') {
document.getElementById('sgmt' + thecurrentone).innerHTML=tzn;
} else {
document.getElementById('sgmt' + thecurrentone).innerHTML=selo.value;
}
document.getElementById('tspec' + thecurrentone).innerHTML=' GMT';
}
}
function emailtalk(divo) {
zero=0;
console.log('1');
thecurrentone=('' + divo.id).replace('divn','');
if (thecurrentone != '') { zero=eval(-1 + eval('' + thecurrentone)); }
console.log('2');
var parts=divo.innerHTML.split('[');
if (parts.length > 1) {
parts[0]=parts[1].split(']')[0];
}
console.log('parts[0]=' + parts[0]);
if (divo.innerHTML.trim() != '') { //} && divo.innerHTML.indexOf('@') != -1) {
console.log('11');
iflist[zero]=document.getElementById('spananswer' + thecurrentone).innerHTML;
if ((1 == 1 || divo.innerHTML.indexOf(']') > divo.innerHTML.indexOf('@')) && divo.innerHTML.indexOf('[') < divo.innerHTML.indexOf('@') && divo.innerHTML.indexOf('[') != -1) {
emailee[zero]='' + divo.innerHTML.split('[')[1].split(']')[0];
//document.getElementById('mybut' + thecurrentone).value='Check my Datetime Above via Email ' + emailee[zero] + ' Correspondence';
if (divo.innerHTML.indexOf('@') != -1) {
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
} else {
//alert(1);
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
}
divo.innerHTML=divo.innerHTML.replace('[' + emailee[zero],'').replace(']','');
} else if (parts.length > 1 && parts[0].replace(/0/g,'').replace(/1/g,'').replace(/2/g,'').replace(/3/g,'').replace(/4/g,'').replace(/5/g,'').replace(/6/g,'').replace(/7/g,'').replace(/8/g,'').replace(/9/g,'') == '' && parts[0] != '') {
console.log('12');
parts=divo.innerHTML.split('[');
emailee[zero]='' + divo.innerHTML.split('[')[1].split(']')[0];
if (divo.innerHTML.indexOf('@') != -1) {
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
} else {
//alert(11);
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
}
divo.innerHTML=divo.innerHTML.replace('[' + emailee[zero],'').replace(']','');
} else if (divo.innerHTML.trim() != '' && divo.innerHTML.indexOf('@') != -1) {
console.log('13');
emailee[zero]='' + divo.innerHTML;
//document.getElementById('mybut' + thecurrentone).value='Check my Datetime Above via Email ' + emailee[zero] + ' Correspondence';
if (divo.innerHTML.indexOf('@') != -1) {
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
} else {
//alert(111);
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
}
} else if (divo.innerHTML.trim() != '' && divo.innerHTML.replace(/0/g,'').replace(/1/g,'').replace(/2/g,'').replace(/3/g,'').replace(/4/g,'').replace(/5/g,'').replace(/6/g,'').replace(/7/g,'').replace(/8/g,'').replace(/9/g,'') == '' && parts[0] != '') {
console.log('14');
emailee[zero]='' + divo.innerHTML;
//document.getElementById('mybut' + thecurrentone).value='Check my Datetime Above via Email ' + emailee[zero] + ' Correspondence';
if (divo.innerHTML.indexOf('@') != -1) {
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>Email ' + emailee[zero] + ' Correspondence';
} else {
//alert(1111);
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
butb[zero]='Check my Datetime Above via <br>SMS ' + emailee[zero] + ' Correspondence';
}
} else {
if (butb[zero].indexOf('<br') == -1) {
emailee[zero]='';
//document.getElementById('mybut' + thecurrentone).value='Check my Datetime Above';
//alert(0);
document.getElementById('mybut' + thecurrentone).innerHTML='Check my Datetime Above';
butb[zero]='Check my Datetime Above';
}
}
}
}
function check_if1(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function dowhat(insis) {
if (insis.indexOf('parent.') != -1 && insis.indexOf('function ifonl() {') != -1 && insis.indexOf('} }') != -1) {
//alert(insis.split('function ifonl() {')[1].split('} }')[0].replace(/parent\./g,'') + '}');
if (1 == 5) {
eval(insis.split('function ifonl() {')[1].split('} }')[0].replace(/parent\./g,'') + '}');
}
}
return insis;
}
function check_if2(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (dowhat(aconto.body.innerHTML).indexOf('parent.') != -1) {
//alert('2:' + aconto.body.innerHTML);
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if3(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if4(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
console.log('4 found index ' + eval(-1 + eval(iois.id.replace('myif',''))) + ': ' + iois.src);
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if5(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if6(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if7(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if8(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function check_if9(iois) {
var ifnd=-1;
if (iois != null) {
ifnd=iois.src.indexOf('answer=');
var aconto = (iois.contentWindow || iois.contentDocument);
if (aconto != null && ifnd != -1) {
if (aconto.document) { aconto = aconto.document; }
if (aconto.body != null) {
if (aconto.body.innerHTML.indexOf('parent.') != -1) {
iflist[eval(-1 + eval(iois.id.replace('myif','')))]+=' ';
iois.src='./since_1970.php?' + iois.src.split('?')[1].split('&answer=')[0] + '&rand=' + Math.floor(Math.random() * 19876754);
}
}
} else if (ifnd != -1) {
ifnd=ifnd;
}
}
}
function iflistcheck() {
for (var ii=1; ii<=iflist.length; ii++) {
if (iflist[eval(-1 + ii)] != '' && iflist[eval(-1 + ii)].indexOf(' ') == -1) {
//alert('./since1970_' + iflist[eval(-1 + ii)] + '_' + ii + '.html?player=' + ii + '&bignum=' + iflist[eval(-1 + ii)] + '&answer=&rand=' + Math.floor(Math.random() * 1987654345));
if (iflist[eval(-1 + ii)].indexOf(document.getElementById('spananswer' + ('' + ii).replace('1','')).innerHTML) == -1) {
iflist[eval(-1 + ii)]=document.getElementById('spananswer' + ('' + ii).replace('1','')).innerHTML;
uselong[eval(-1 + ii)]=true;
}
if (uselong[eval(-1 + ii)]) {
uselong[eval(-1 + ii)]=false;
document.getElementById('myif' + ii).src='./since1970_' + iflist[eval(-1 + ii)] + '_' + ii + '.html?player=' + ii + '&bignum=' + iflist[eval(-1 + ii)] + '&answer=&rand=' + Math.floor(Math.random() * 1987654345);
} else {
uselong[eval(-1 + ii)]=true;
document.getElementById('myif' + ii).src='./since1970_' + ii + '.htm?player=' + ii + '&bignum=' + iflist[eval(-1 + ii)] + '&answer=&rand=' + Math.floor(Math.random() * 1987654345);
}
} else if (iflist[eval(-1 + ii)] != '' && iflist[eval(-1 + ii)].indexOf(' ') != -1) {
if (iflist[eval(-1 + ii)].indexOf(document.getElementById('spananswer' + ('' + ii).replace('1','')).innerHTML) == -1) {
iflist[eval(-1 + ii)]=document.getElementById('spananswer' + ('' + ii).replace('1','')).innerHTML;
uselong[eval(-1 + ii)]=true;
//alert('Send off email for ' + (document.getElementById('divn' + ii).innerText || document.getElementById('divn' + ii).contentWindow || document.getElementById('divn' + ii).contentDocument));
document.getElementById('mybut' + ('' + ii).replace('1','')).click();
if (uselong[eval(-1 + ii)]) {
uselong[eval(-1 + ii)]=false;
document.getElementById('myif' + ii).src='./since1970_' + iflist[eval(-1 + ii)] + '_' + ii + '.html?player=' + ii + '&bignum=' + iflist[eval(-1 + ii)] + '&answer=&rand=' + Math.floor(Math.random() * 1987654345);
} else {
uselong[eval(-1 + ii)]=true;
document.getElementById('myif' + ii).src='./since1970_' + ii + '.htm?player=' + ii + '&bignum=' + iflist[eval(-1 + ii)] + '&answer=&rand=' + Math.floor(Math.random() * 1987654345);
}
}
}
}
setTimeout(iflistcheck, 5000);
}
function firstaskcheck() {
playernum=location.search.split('player=')[1] ? decodeURIComponent(location.search.split('player=')[1].split('&')[0]) : '';
pl=location.search.split('pl=')[1] ? decodeURIComponent(location.search.split('pl=')[1].split('&')[0]) : '';
sc=location.search.split('sc=')[1] ? decodeURIComponent(location.search.split('sc=')[1].split('&')[0]) : '';
bignum=location.search.split('bignum=')[1] ? decodeURIComponent(location.search.split('bignum=')[1].split('&')[0]) : '';
if (playernum != '' && (document.URL + '#').indexOf('answer=#') != -1) {
ansis=prompt('Enter dd/mm/yyyy hh:mi:ss answer ( eg. 15/06/2011 13:45:42 ) equivalent to ' + bignum + ' seconds since 1/1/1970', '');
if (ansis == null) { ansis=''; }
if (ansis.trim() != '') {
location.href=document.URL.split('#')[0].replace('.html','.php').replace('.htm','.php') + encodeURIComponent(ansis);
}
}
}
if (1 == 5) {
playernum=location.search.split('player=')[1] ? decodeURIComponent(location.search.split('player=')[1].split('&')[0]) : '';
pl=location.search.split('pl=')[1] ? decodeURIComponent(location.search.split('pl=')[1].split('&')[0]) : '';
sc=location.search.split('sc=')[1] ? decodeURIComponent(location.search.split('sc=')[1].split('&')[0]) : '';
bignum=location.search.split('bignum=')[1] ? decodeURIComponent(location.search.split('bignum=')[1].split('&')[0]) : '';
if (playernum != '' && (document.URL + '#').indexOf('answer=#') != -1) {
ansis=prompt('Enter dd/mm/yyyy hh:mi:ss answer ( eg. 15/06/2011 13:45:42 ) equivalent to ' + bignum + ' seconds since 1/1/1970', '');
if (ansis == null) { ansis=''; }
if (ansis.trim() != '') {
location.href=document.URL.split('#')[0].replace('.html','.php').replace('.htm','.php') + encodeURIComponent(ansis);
} else {
window.close();
}
}
}
setTimeout(iflistcheck, 5000);
</script>
</head>
<body onload=" document.getElementById('inumplayers').value='' + numplayers; document.getElementById('olocal').value+=tzo; document.getElementById('myform').action=document.URL.split('#')[0].split('?')[0].replace('.html','.php').replace('.htm','.php'); document.getElementById('olocal').innerHTML+=tzo; display(); if (1 == 1) { setTimeout(firstaskcheck,1000); } ">
<h1>Big Number (Starts at 1/1/1970) Date and Time Guessing via Seconds Since Game for <input id=inumplayers style=display:inline-block;width:35px; type=number step=1 min=1 max=9 onblur="if (eval(this.value) > 1 || document.URL.indexOf('numplayers=') != -1) { location.href=document.URL.split('#')[0].split('?')[0] + '?numplayers=' + this.value; }" value=1></input> Player(s)</h1>
<h3>RJM Programming <a style=cursor:pointer;text-decoration:underline; onclick=showperfect(); title='Best answer to ? seconds since 1/1/1970 was ...' id=asp>-</a> March, 2022</h3>
<table id=outertable><thead id=mythead></thead><tbody id=mytbody><tr id=row1><td id=cell1>
<table border=20>
<tr><th id=thscore>Points left: <span class=score id=score></span> Survival count: <span class=goes id=goes></span></th></tr>
<tr><th id=secanswer>Seconds since 1/1/1970<span id=tspec></span>: <span title='Click for year count calculator and double click for day count calculator' onclick=startcalculatory(this); ondblclick=startcalculatord(this); style=cursor:pointer;text-decoration:none; class=spananswer id=spananswer></span> ... try to match <span id=sgmt>GMT</span> datetime closely below, else lose points</th></tr>
<tr><td style=text-align:center;><br><form id=myform method=GET action='./since_1970.html'><input type=hidden name=myindex value=""></input>
<input style=display:inline-block;min-width:28px; onblur=fixitzero(this,1,31); onchange=fixitzero(this,1,31); type="text" title="Date" id="sday" name="sday" value="01"></input>/<select style=display:inline-block; id="smonth" name="smonth" title="Month"><option value="01">January</option><option value="02">February</option><option value="03">March</option><option value="04">April</option><option value="05">May</option><option value="06">June</option><option value="07">July</option><option value="08">August</option><option value="09">September</option><option value="10">October</option><option value="11">November</option><option value="12">December</option></select>/<input style=display:inline-block;min-width:55px; onblur=fixitzero(this,1970,nts); onchange=fixitzero(this,1970,nts); step=1 min=1970 type="number" id="syear" name="syear" value="1970" title="Year"></input> <input onblur=fixitzero(this,0,23); onchange=fixitzero(this,0,23); style=display:inline-block;min-width:28px; type="text" id="shour" name="shour" value="00" title="Hours"></input>:<input onblur=fixitzero(this,0,59); onchange=fixitzero(this,0,59); title="Minutes" style=display:inline-block;min-width:28px; type="text" id="sminute" name="sminute" value="00"></input>:<input onblur=fixitzero(this,0,59); onchange=fixitzero(this,0,59); title="Seconds" style=display:inline-block;min-width:28px; type="text" id="ssecond" name="ssecond" value="00"></input><span> <select style=display:inline-block; name=seltz id=seltz onchange=tzit(this);><option value=GMT>GMT</option><option id=olocal value=Local>Local</option></select></span><br>
</form><br></td></tr>
<tr><td style=text-align:center;><br><input style=display:NONE; type=submit value='Reply With My Date Above'></input><button style=display:block;margin-left:30%; class=mybut id=mybut data-type=button onclick=checkanswer(this); data-value='Check my Datetime Above'>Check my Datetime Above</button><br><br><iframe style=display:none; id=icalculator src='/PHP/calculator.php' style='width:100%;height:200px;'></iframe></td></tr>
</table>
</td></tr></tbody></table>
<a target=iemail id=emailoff style=display:none; href='mailto:?subject=&body='>Email</a><div style=display:none; id=divscr></div>
<a target=iemail id=smsoff style=display:none; href='sms:&body='>SMS</a><div style=display:none; id=divscr></div>
<div style=display:none; id=divifs>
<iframe style=display:none; id=myif1 src='./since_1970.php' onload=check_if1(this);></iframe>
<iframe style=display:none; id=myif2 src='./since_1970.php' onload=check_if2(this);></iframe>
<iframe style=display:none; id=myif3 src='./since_1970.php' onload=check_if3(this);></iframe>
<iframe style=display:none; id=myif4 src='./since_1970.php' onload=check_if4(this);></iframe>
<iframe style=display:none; id=myif5 src='./since_1970.php' onload=check_if5(this);></iframe>
<iframe style=display:none; id=myif6 src='./since_1970.php' onload=check_if6(this);></iframe>
<iframe style=display:none; id=myif7 src='./since_1970.php' onload=check_if7(this);></iframe>
<iframe style=display:none; id=myif8 src='./since_1970.php' onload=check_if8(this);></iframe>
<iframe style=display:none; id=myif9 src='./since_1970.php' onload=check_if9(this);></iframe>
<iframe style=display:none; name=iemail src='./since_1970.php'></iframe>
</div>
</body>
</html>