Fix formatting

This commit is contained in:
Mcat12 2016-12-30 12:59:05 -05:00
parent 09bbc81470
commit 089b98430f

View file

@ -90,32 +90,32 @@ if($uri == "/")
<script src="http://<?php echo $_SERVER['SERVER_ADDR']; ?>/admin/js/other/jquery.min.js"></script> <script src="http://<?php echo $_SERVER['SERVER_ADDR']; ?>/admin/js/other/jquery.min.js"></script>
<script src="http://<?php echo $_SERVER['SERVER_ADDR']; ?>/admin/js/pihole/queryads.js"></script> <script src="http://<?php echo $_SERVER['SERVER_ADDR']; ?>/admin/js/pihole/queryads.js"></script>
<script> <script>
function inIframe () { function inIframe () {
try { try {
return window.self !== window.top; return window.self !== window.top;
} catch (e) { } catch (e) {
return true; return true;
} }
} }
// Try to detect if page is loaded within iframe // Try to detect if page is loaded within iframe
if(inIframe()) if(inIframe())
{ {
// Within iframe // Within iframe
// hide content of page // hide content of page
$('#body').hide(); $('#body').hide();
// remove background // remove background
document.body.style.backgroundImage = "none"; document.body.style.backgroundImage = "none";
} }
else else
{ {
// Query adlists // Query adlists
$( "#btnSearch" ).click(); $( "#btnSearch" ).click();
} }
$( "#whitelisting" ).on( "click", function(){ $( "#whitelistingform" ).removeAttr( "hidden" ); }); $( "#whitelisting" ).on( "click", function(){ $( "#whitelistingform" ).removeAttr( "hidden" ); });
function add() { function add() {
var domain = $("#domain"); var domain = $("#domain");
var pw = $("#pw"); var pw = $("#pw");
if(domain.val().length === 0){ if(domain.val().length === 0){