// qsall.js // RJM Programming // January, 2021 // Help out qsall.htm var ourlastc=''; var lastls=0; var ournum=''; var ajs=location.search.split("thescript=")[1] ? decodeURIComponent(location.search.split("thescript=")[1].split('&')[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; var tas=location.search.split("thecontent=")[1] ? decodeURIComponent(location.search.split("thecontent=")[1].split('&')[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; if (document.URL.indexOf('clear=') != -1) { lastls=0; while (('' + window.localStorage.getItem('qsall' + eval(1 + lastls))).replace(/\+/g,' ').replace(/^null$/g,'') != '') { window.localStorage.removeItem('qsall' + eval(1 + lastls)); lastls++; } lastls=0; } function emaillastc() { if (ourlastc != '') { document.getElementById('emailsms').href='mailto:?subject=' + encodeURIComponent('URL (with optional user styling and scripting) ...') + '&body=' + encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '?thecontent=' + encodeURIComponent(ourlastc)); document.getElementById('emailsms').click(); } } function twoencodeURIComponent(invl) { if (navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { return invl; } else { return encodeURIComponent(invl); } } function smslastc() { if (ourlastc != '') { ournum=prompt('Who do you want to SMS to?', ournum); if (ournum == null) { ournum=''; } if (ournum != '') { document.getElementById('emailsms').href='sms:' + ournum + '&body=' + twoencodeURIComponent(encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '?thecontent=' + encodeURIComponent(ourlastc))); document.getElementById('emailsms').click(); } } } function savelastc() { if (ourlastc != '') { lastls=0; while (decodeURIComponent(('' + window.localStorage.getItem('qsall' + eval(1 + lastls))).replace(/\+/g,' ').replace(/^null$/g,'')) != '') { lastls++; } window.localStorage.setItem('qsall' + eval(1 + lastls), encodeURIComponent(ourlastc)); extonl(false); ourlastc=''; document.getElementById('dsave').style.display='none'; } } function savebut(inct) { if (document.getElementById('myh1')) { if (document.getElementById('zdivmode')) { document.getElementById('zdivmode').innerHTML=' ...
      '; } else if (('' + document.getElementById('myh1').innerHTML).indexOf('uerySelectorAll') != -1) { document.getElementById('myh1').innerHTML=document.getElementById('myh1').innerHTML.split('uerySelectorAll')[0] + 'uerySelectorAll ...
      '; } else if (('' + document.getElementById('myh1').innerHTML).indexOf('') != -1) { document.getElementById('myh1').innerHTML=document.getElementById('myh1').innerHTML.split('')[0] + ' ...
      '; } } ourlastc=inct; return inct; } function dotas() { if (tas.trim() != '') { if (document.getElementById('myinput')) { document.getElementById('myinput').value=tas; if (document.getElementById('myinput').outerHTML.indexOf(' onblur="') != -1) { eval(document.getElementById('myinput').outerHTML.split(' onblur="')[1].split('"')[0].replace("(this", "(document.getElementById('myinput')").replace(/\,\ /g,',').replace(/\,this/g, ",document.getElementById('myinput')")); } else if (document.getElementById('myinput').outerHTML.indexOf(" onblur='") != -1) { eval(document.getElementById('myinput').outerHTML.split(" onblur='")[1].split("'")[0].replace("(this", "(document.getElementById('myinput')").replace(/\,\ /g,',').replace(/\,this/g, ",document.getElementById('myinput')")); } else if (document.getElementById('myinput').outerHTML.indexOf(' onblur=') != -1) { eval(document.getElementById('myinput').outerHTML.split(' onblur=')[1].split(" ")[0].split(">")[0].replace("(this", "(document.getElementById('myinput')").replace(/\,\ /g,',').replace(/\,this/g, ",document.getElementById('myinput')")); } } tas=''; } else if (tas != '') { lastls=0; while (('' + window.localStorage.getItem('qsall' + eval(1 + lastls))).replace(/\+/g,' ').replace(/^null$/g,'') != '') { window.localStorage.removeItem('qsall' + eval(1 + lastls)); lastls++; } lastls=0; tas=''; } } function extonl(isfirst) { if (isfirst) { if (ajs.trim() == '') { if (document.head.innerHTML.indexOf('qsall.js?thescript=') != -1) { ajs=document.head.innerHTML.split("qsall.js?thescript=")[1] ? decodeURIComponent(document.head.innerHTML.split("qsall.js?thescript=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } else if (document.body.innerHTML.indexOf('?thescript=') != -1) { ajs=document.body.innerHTML.split("?thescript=")[1] ? decodeURIComponent(document.body.innerHTML.split("?thescript=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } else if (document.body.innerHTML.indexOf('&thescript=') != -1) { ajs=document.body.innerHTML.split("&thescript=")[1] ? decodeURIComponent(document.body.innerHTML.split("&thescript=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } } if (tas.trim() == '') { if (document.head.innerHTML.indexOf('qsall.js?thecontent=') != -1) { tas=document.head.innerHTML.split("qsall.js?thecontent=")[1] ? decodeURIComponent(document.head.innerHTML.split("qsall.js?thecontent=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } else if (document.body.innerHTML.indexOf('?thecontent=') != -1) { tas=document.body.innerHTML.split("?thecontent=")[1] ? decodeURIComponent(document.body.innerHTML.split("?thecontent=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } else if (document.body.innerHTML.indexOf('&thecontent=') != -1) { tas=document.body.innerHTML.split("&thecontent=")[1] ? decodeURIComponent(document.body.innerHTML.split("&thecontent=")[1].split('&')[0].split('>')[0].split('"')[0].split("'")[0]).replace(/\;\ /g, '; ' + String.fromCharCode(10)) : ""; } } } if (ajs.trim() != '') { var tag = document.createElement('script'); tag.type='text/javascript'; tag.src='data:text/javascript;base64,' + btoa(ajs); document.head.appendChild(tag); ajs=''; } dotas(); if (document.getElementById('myh1')) { var repwith=' out '; if (('' + document.getElementById('myh1').innerHTML).indexOf(' out ') != -1) { lastls=0; while (decodeURIComponent(('' + window.localStorage.getItem('qsall' + eval(1 + lastls))).replace(/\+/g,' ').replace(/^null$/g,'')) != '') { if (repwith == ' out ') { repwith=' '; } repwith=repwith.replace('', ''); lastls++; } if (repwith != ' out ') { document.getElementById('myh1').innerHTML=document.getElementById('myh1').innerHTML.replace(' out ', repwith); } else if (!isfirst && ourlastc != '') { if (repwith == ' out ') { repwith=' '; } repwith=repwith.replace('', ''); document.getElementById('myh1').innerHTML=document.getElementById('myh1').innerHTML.replace(' out ', repwith); } else { if (repwith == ' out ') { repwith=' '; } document.getElementById('myh1').innerHTML=document.getElementById('myh1').innerHTML.replace(' out ', repwith); } } } }