Dim Arr, enter Arr = array("1.1","1.2.3.4","127.0.0.1") Arr_ea = UBound(Arr) dim strIp dim allow_ip strIp = request.ServerVariables("REMOTE_ADDR") '접속자IP를 받아옴
enter = false
For i=0 to Arr_ea If strIp = Arr(i) Then ' Response.write "ok" enter = true Else ' Response.write "no" End if Next
'response.write enter If enter = false Then response.write "<script language='javascript' >" response.write "alert('접속권한이 없습니다.');" response.write "history.go(-1);" '초기 페이지로 response.write "</script>" End If
|