1
<%
function getip(ip)
strIpArr = Split(ip,".")
strGetUserIP = strIpArr(0)
strGetUserIP = strGetUserIP & "." & strIpArr(1)
strGetUserIP = strGetUserIP & "." & strIpArr(2)
strGetUserIP = strGetUserIP & ".*"
getip=strGetUserIP
end function
response.write getip("127.0.0.1")
%>
2-----------
<SCRIPT LANGUAGE="VBScript">
document.write denyIp("192.168.0.1")
Function denyIp(ip)
denyIp = mid(ip,1,InstrRev(ip,"."))&"*"
End Function
</SCRIPT>