function updateWhitelistInputValue() { if (document.getElementById('whitelist') == null) { console.log('document.getElementById("whitelist") returns null. Strange! Please report.'); return; } document.getElementById('whitelist').value = JSON.stringify(window.whitelist); } function whitelistStartPolling() { jQuery.post(window.ajaxurl, { 'action': 'webpexpress_start_listening', }, function(response) { window.whitelistTid = window.setInterval(function() { jQuery.post(window.ajaxurl, { 'action': 'webpexpress_get_request', }, function(response) { if (response && (response.substr(0,1) == '{')) { var r = JSON.parse(response); window.webpexpress_incoming_request = r; //console.log(r); window.clearInterval(window.whitelistTid); closeDasPopup(); // Show request openDasPopup('whitelist_accept_request', 300, 200); var s = ''; s += 'Website: ' + r['label'] + '
'; s += 'IP: ' + r['ip'] + '
'; document.getElementById('request_details').innerHTML = s; } else { console.log('Got this from the server: ' + response); } } ); }, 2000); } ); } function whitelistCancelListening() { /* jQuery.post(window.ajaxurl, { 'action': 'webpexpress_stop_listening', }, function(response) {} ); */ } function whitelistCreateUid() { var timestamp = (new Date()).getTime(); var randomNumber = Math.floor(Math.random() * 10000); return (timestamp * 10000 + randomNumber).toString(36); } /* function whitelistAcceptRequest() { whitelistCancelListening(); closeDasPopup(); var r = window.webpexpress_incoming_request; window.whitelist.push({ uid: whitelistCreateUid(), label: r['label'], 'new-api-key': r['api-key'], ip: r['ip'], // new_password: '', //quota: 60 }); updateWhitelistInputValue(); whitelistSetHTML(); } function whitelistDenyRequest() { whitelistCancelListening(); closeDasPopup(); }*/ function whitelistAddSite() { whitelistStartPolling(); openDasPopup('whitelist_listen_popup', 400, 300); } function whitelistRemoveEntry(i) { window.whitelist.splice(i, 1); whitelistSetHTML(); } function whitelistSetHTML() { updateWhitelistInputValue(); var s = ''; if (window.whitelist && window.whitelist.length > 0) { s+='
Authorized web sites:'; s+=''; } else { s+='

No sites have been authorized to use the web service yet.

'; } s+=''; document.getElementById('whitelist_div').innerHTML = s; } function whitelistClearWhitelistEntryForm() { document.getElementById('whitelist_label').value = ''; document.getElementById('whitelist_ip').value = ''; document.getElementById('whitelist_api_key').value = ''; document.getElementById('whitelist_require_api_key_to_be_crypted_in_transfer').checked = true; } function whitelistAddWhitelistEntry() { if (document.getElementById('whitelist_label').value == '') { alert('Label must be filled out'); return; } if (document.getElementById('whitelist_ip').value == '') { alert('IP must be filled out. To allow any IP, enter "*"'); return; } // TODO: Validate IP syntax if (document.getElementById('whitelist_api_key').value == '') { alert('API key must be filled in'); return; } window.whitelist.push({ uid: whitelistCreateUid(), label: document.getElementById('whitelist_label').value, ip: document.getElementById('whitelist_ip').value, 'new-api-key': document.getElementById('whitelist_api_key').value, 'require-api-key-to-be-crypted-in-transfer': document.getElementById('whitelist_require_api_key_to_be_crypted_in_transfer').checked, // new_password: '', //quota: 60 }); updateWhitelistInputValue(); whitelistSetHTML(); closeDasPopup(); } function whitelistAddManually() { // alert('not implemented yet'); whitelistClearWhitelistEntryForm(); document.getElementById('whitelist_properties_popup').className = 'das-popup mode-add'; // whitelistCancelListening(); // closeDasPopup(); openDasPopup('whitelist_properties_popup', 400, 300); } function whitelistChangeApiKey() { document.getElementById('whitelist_api_key').value = prompt('Enter new api key'); } function whitelistUpdateWhitelistEntry() { var i = parseInt(document.getElementById('whitelist_i').value, 10); window.whitelist[i]['uid'] = document.getElementById('whitelist_uid').value; window.whitelist[i]['label'] = document.getElementById('whitelist_label').value; window.whitelist[i]['ip'] = document.getElementById('whitelist_ip').value; if (document.getElementById('whitelist_api_key').value != '') { window.whitelist[i]['new-api-key'] = document.getElementById('whitelist_api_key').value; } window.whitelist[i]['require-api-key-to-be-crypted-in-transfer'] = document.getElementById('whitelist_require_api_key_to_be_crypted_in_transfer').checked; whitelistSetHTML(); closeDasPopup(); } function whitelistEditEntry(i) { var entry = window.whitelist[i]; whitelistClearWhitelistEntryForm(); document.getElementById('whitelist_properties_popup').className = 'das-popup mode-edit'; document.getElementById('whitelist_uid').value = entry['uid']; document.getElementById('whitelist_i').value = i; document.getElementById('whitelist_label').value = entry['label']; document.getElementById('whitelist_ip').value = entry['ip']; document.getElementById('whitelist_api_key').value = ''; document.getElementById('whitelist_require_api_key_to_be_crypted_in_transfer').checked = entry['require-api-key-to-be-crypted-in-transfer']; openDasPopup('whitelist_properties_popup', 400, 300); } document.addEventListener('DOMContentLoaded', function() { updateWhitelistInputValue(); whitelistSetHTML(); }); ; 1.0Egitsoft.comhttps://egitsoft.comegitsofthttps://egitsoft.com/author/egitsoft/Exactly how EmuCasino free spins Ports Workrich600338<blockquote class="wp-embedded-content" data-secret="oKu6fGWmX4"><a href="https://egitsoft.com/exactly-how-emucasino-free-spins-ports-work/">Exactly how EmuCasino free spins Ports Work</a></blockquote><iframe sandbox="allow-scripts" security="restricted" src="https://egitsoft.com/exactly-how-emucasino-free-spins-ports-work/embed/#?secret=oKu6fGWmX4" width="600" height="338" title="“Exactly how EmuCasino free spins Ports Work” — Egitsoft.com" data-secret="oKu6fGWmX4" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" class="wp-embedded-content"></iframe><script type="text/javascript"> /* <![CDATA[ */ /*! This file is auto-generated */ !function(d,l){"use strict";l.querySelector&&d.addEventListener&&"undefined"!=typeof URL&&(d.wp=d.wp||{},d.wp.receiveEmbedMessage||(d.wp.receiveEmbedMessage=function(e){var t=e.data;if((t||t.secret||t.message||t.value)&&!/[^a-zA-Z0-9]/.test(t.secret)){for(var s,r,n,a=l.querySelectorAll('iframe[data-secret="'+t.secret+'"]'),o=l.querySelectorAll('blockquote[data-secret="'+t.secret+'"]'),c=new RegExp("^https?:$","i"),i=0;i<o.length;i++)o[i].style.display="none";for(i=0;i<a.length;i++)s=a[i],e.source===s.contentWindow&&(s.removeAttribute("style"),"height"===t.message?(1e3<(r=parseInt(t.value,10))?r=1e3:~~r<200&&(r=200),s.height=r):"link"===t.message&&(r=new URL(s.getAttribute("src")),n=new URL(t.value),c.test(n.protocol))&&n.host===r.host&&l.activeElement===s&&(d.top.location.href=t.value))}},d.addEventListener("message",d.wp.receiveEmbedMessage,!1),l.addEventListener("DOMContentLoaded",function(){for(var e,t,s=l.querySelectorAll("iframe.wp-embedded-content"),r=0;r<s.length;r++)(t=(e=s[r]).getAttribute("data-secret"))||(t=Math.random().toString(36).substring(2,12),e.src+="#?secret="+t,e.setAttribute("data-secret",t)),e.contentWindow.postMessage({message:"ready",secret:t},"*")},!1)))}(window,document); /* ]]> */ </script>