(function($){ $.fn.invisible = function(){ return this.each(function(){ $(this).css("display", "none"); }); }; $.fn.visible = function(){ return this.each(function(){ $(this).css("display", "block"); }); }; }(jQuery)); $(document).ready(function() { $(".Search").keyup(function(event){ if(event.keyCode == 13){ $("#search_button").click(); } }); $('#search_button').click(function(event){ var url = $('#Search').val(); if(url != '') { $.ajax({ type: "POST", url: "http://www.whois.octenium.com/includes/valid_url.php", data: {'url':url}, cache: false, dataType: "json", success: function(data) { if(data[0] == 1) search_whois_detail(url,event) else $("#tooltip-error").visible(); } }); } }); }); function search_whois_detail(url,e) { if (!e) e = window.event; if (!e.ctrlKey) { var EventType = e.type; $("#tooltip-error").invisible(); $('.loader-ctrl').fadeIn('fast'); document.title = capitalise(url+" Whois"); window.history.pushState(url, capitalise(url)+ " Whois Octenium ","http://www.whois.octenium.com/"+url+".html"); $(".page").removeClass("active"); $("#Search").val(url); $.ajax({ type: "POST", url: "http://www.whois.octenium.com/show.php", data: {'url':url,'type':'rawdata'}, cache: false, dataType: "json", success: function(data) { $('.loader-ctrl').fadeOut('slow',function(){}); if(data[0] == 0) { if(EventType == "click") { $("#tooltip-error").visible(); } else { var title = 'Whois Octenium'; document.title = capitalise(title); window.history.pushState(title, capitalise('home')+ " Whois Octenium ","http://www.whois.octenium.com"); $("#default-index-page").visible(); $("#domain-info").invisible(); $("#default-index-page").html(data[1]); $('.inner-mrg').responsiveEqualHeightGrid(); $(window).scrollTop($('#default-index-page').offset().top); } } else { $("#default-index-page").invisible(); $("#domain-info").visible(); $("#whois-domain-detail").html(data[0]); $("#raw_registrar_data").html('
' + data[1] + ''); $(window).scrollTop($('#domain-info').offset().top); $.ajax({ type: "POST", url: "http://www.whois.octenium.com/show.php", data: {'url':url,'type':'Site-Stats'}, cache: false, dataType: "json", success: function(data) { if(data[0] == 0) { $("#tooltip-error").visible(); } else { $("#Site-Stats").html(data[0]); } } }); $.ajax({ type: "POST", url: "http://www.whois.octenium.com/show.php", data: {'url':url,'type':'SEO-Stats'}, cache: false, dataType: "json", success: function(data) { if(data[0] == 0) { $("#tooltip-error").visible(); } else { $("#SEO-Stats").html(data[0]); } } }); } } }); return false; } } function capitalise(string) { return string; } function change_pages(page,title,e) { if (!e) e = window.event; if (!e.ctrlKey) { var status_of_loader = ''; document.getElementById('Search').value= ''; if(page == 'home') document.title = capitalise("Whois Octenium"); else document.title = capitalise(title); $(".page").removeClass("active"); $("#"+page).addClass('active'); if(page == 'home') window.history.pushState(title, capitalise(page)+ " Whois Octenium ","http://www.whois.octenium.com"); else window.history.pushState(title, capitalise(page)+ " Whois Octenium ","http://www.whois.octenium.com/page/"+page); $("#tooltip-error").invisible(); $.ajax({ type:"POST", url: "http://www.whois.octenium.com/page.php", data: {'page':page}, dataType: "json", success: function(data) { $("#domain-info").invisible(); $("#default-index-page").visible(); $("#default-index-page").html(data['0']); if(page == 'home') $('.inner-mrg').responsiveEqualHeightGrid(); } }); return false; } } function contact_page(page,e) { } function change_recent(p,e) { } function getParameter(theParameter) { var params = window.location.search.substr(1).split('&'); for (var i = 0; i < params.length; i++) { var p=params[i].split('='); if (p[0] == theParameter) { return decodeURIComponent(p[1]); } } return false; } function change_language(language,e) { if (!e) e = window.event; if (!e.ctrlKey) { var currentLocation = window.location; $.ajax({ type: "POST", url: "http://www.whois.octenium.com/change_language.php", data: {language: language}, cache: false, success: function(result) { window.location=currentLocation; } }); return false; } } function mailsend() { } $(window).load(function(e) { $.ajax({ type:"POST", url: "http://www.whois.octenium.com/includes/count_stats.php", data: {'pageViews':'1'}, }); $.ajax({ type:"POST", url: "http://www.whois.octenium.com/includes/count_stats.php", data: {'uniqueHits':'1'}, }); }); jQuery(function($) { $('.inner-mrg').responsiveEqualHeightGrid(); });