6,9c6
<
< var czhr=null;
< var czform=null;
<
---
>
16,20d12
< var tmks='';
< var canvc=' ', lastcanvc=' ';
< var accl='image/*,video/*,audio/*,application/*,text/*';
< var postlt='left:60%;top:calc(100% - 50px);';
< var cci='Url';
28c20
< if ((document.head.innerHTML + document.body.innerHTML).indexOf('web_share_api_test.js?pop' + 'ulate=') != -1 && (!document.getElementById('files') || !document.getElementById('output') || !document.getElementById('shareurl') || !document.getElementById('share'))) {
---
> if ((document.head.innerHTML + document.body.innerHTML).indexOf('web_share_api_test.js?populate=') != -1 && (!document.getElementById('files') || !document.getElementById('output') || !document.getElementById('shareurl') || !document.getElementById('share'))) {
38,120d29
< } else if ((document.head.innerHTML + document.body.innerHTML).indexOf('web_share_api_test.js?canv' + 'asshare=') != -1 && (!document.getElementById('files') || !document.getElementById('output') || !document.getElementById('shareurl') || !document.getElementById('share'))) {
< if (navigator.canShare) {
< canvc=tctowebp();
< cci='Canvas Content Image URL';
< setInterval(tctowebp, 20000);
< tmks='Canvas contents.';
< shareData = {
< title: 'Canvas Content Share',
< text: 'Canvas Content Share',
< url: document.URL.substring(0,9) + document.URL.substring(9).split('/')[0] + '/canvas.webp'
< };
< if (document.URL.indexOf('/localhost') != -1) {
< accl='.webp';
< }
< if (document.getElementById('dcm')) {
< //alert(document.URL.toUpperCase());
< document.getElementById('dcm').innerHTML+="
";
< } else if (document.URL.indexOf('/signature_signature.htm') != -1) {
< if (window.parent && document.URL.indexOf('/user_of_signature_signature.htm') == -1) {
< if (parent.document.URL.indexOf('/user_of_signature_signature.htm') != -1 && 1 == 1) {
< postlt+='left:-1300px;top:-1200px;display:none;';
< }
< }
< //alert(document.URL.toLowerCase() + ' ... ' + postlt);
< document.body.innerHTML+="
";
< if (postlt.indexOf('display:none') != -1) { setTimeout(eventuallyshow, 20000); }
< } else if (document.URL.indexOf('/user_of_signature_signature.htm') != -1) {
< document.body.innerHTML+="
";
< if (postlt.indexOf('display:none') != -1) { setTimeout(eventuallyshow, 20000); }
< }
< }
< }
<
< function cstateChanged() {
< if (czhr.readyState == 4) {
< if (czhr.status == 200) {
< if (1 == 2) { alert('Did it'); }
< if (document.getElementById('shareurl')) {
< document.getElementById('shareurl').style.backgroundColor='yellow';
< }
< }
< }
< }
<
< function tctowebp() {
< var ourcanvc='';
< var canvs=[];
< if (window.top) {
< canvs=top.document.getElementsByTagName('canvas');
< }
< if (eval('' + canvs.length) == 0 && window.parent) {
< canvs=parent.document.getElementsByTagName('canvas');
< }
< if (eval('' + canvs.length) == 0) {
< canvs=document.getElementsByTagName('canvas');
< }
< if (eval('' + canvs.length) == 0 && window.parent) {
< canvs=parent.document.getElementsByTagName('canvas');
< if (eval('' + canvs.length) == 0 && window.top) {
< canvs=top.document.getElementsByTagName('canvas');
< }
< }
< if (eval('' + canvs.length) > 0) {
< ourcanvc=canvs[0].toDataURL('image/webp');
< if (lastcanvc != ' ') {
< if (lastcanvc != ourcanvc) {
< lastcanvc=ourcanvc;
< canvc=ourcanvc;
< czhr = new XMLHttpRequest();
< czform = new FormData();
< czform.append('webpit', canvc);
< czhr.onreadystatechange=cstateChanged;
< czhr.open('post', './signature_signature.php', true);
< czhr.send(czform);
< } else {
< if (document.getElementById('shareurl')) {
< document.getElementById('shareurl').style.backgroundColor='#f9f9f9';
< }
< }
< }
< lastcanvc=ourcanvc;
< }
< return ourcanvc;
183,189d91
< if ((document.head.innerHTML + document.body.innerHTML).indexOf('web_share_api_test.js?canv' + 'asshare=') != -1) {
< await navigator.share({
< files,
< title: (bighuh.indexOf('&word' + 'ing=') != -1 ? decodeURIComponent(bighuh.split('&word' + 'ing=')[1].split('&')[0].split('"')[0].split("'")[0]) : tmks),
< text: (bighuh.indexOf('&word' + 'ing=') != -1 ? decodeURIComponent(bighuh.split('&word' + 'ing=')[1].split('&')[0].split('"')[0].split("'")[0]) + ' Take a look at media or documents below' : tmks + ' Take a look at media or documents below' + String.fromCharCode(10) + String.fromCharCode(10))
< });
< } else {
195d96
< }
278,279c179,180
< shareData.text=cci; //'Url';
< shareData.title=cci; //'Url';
---
> shareData.text='Url';
> shareData.title='Url';