Quote:
Originally Posted by Portly_Giraffe
|
very interesting, similar wording to that used by phorm
peter
---------- Post added at 01:10 ---------- Previous post was at 01:04 ----------
pete this works on IIS, but has to be on a .shtml page as the get remote_addr is a server side include
just got to put the relevant ip ranges in
so going to do a redirect on my main page later with a banner like "checking your ISP before i allow you access to my site"
peter
<script language="javascript">
<!--
var ip = '<!--#echo var="REMOTE_ADDR"-->';
if (ip < "86.128.104.255" && ip > "86.128.104.1" ) {
alert("You are visiting this website from an ISP who uses Webwise from Phorm and so your access to this site is blocked ,
your IP is " +ip);
if (confirm("Click OK to learn more at nodpi.org or CANCEL to go to webwise opt out page "))
{location.href="https://nodpi.org" } else {location.href="http://webwise.bt.com" }
}
// -->
</script>