asp 取得用户真实IP,对代理地址仍然有效的函数
'****************************** Function GetUserTrueIP()dim strIPAddrIf Request.ServerVariables("HTTP_X_FORWARDED_FOR") = "" OR InStr(Request.ServerV
'****************************** Function GetUserTrueIP()dim strIPAddrIf Request.ServerVariables("HTTP_X_FORWARDED_FOR") = "" OR InStr(Request.ServerV
代码例子如下:" 'Replace all HTML tag matches with the empty string strOutput = objRegExp.Replace(strHTML, "") 'Replace all with strOutput = Replace(strOut
验证Ip格式 '****************************** Function CheckIp(paR_strIp)CheckIp =0Dim tmpLoop, tmpStrtmpStr =paR_strIpIf tmpStr ="" Or IsNull(tmpStr) Then E
最简单的用以下语句: ip=request.ServerVariables("REMOTE_ADDR")response.Write(ip) 但这种方法对代理服务器上网的就不准了,故比较全面的是用下面的方法: 实现代码如下: 0 ThenstrIPAddr = Request.ServerVaria