<%@Language=VBSCRIPT%> <% 'Dimension variables Dim lngVisitorNumber 'Holds the visitor number Dim intWriteDigitLoopCount 'Loop counter to display the graphical hit count Dim intLowerBound ' Lower bound of the random number range Dim intUpperBound ' Upper bound of the random number range Dim intRangeSize ' Size of the range Dim sngRandomValue ' A random value from 0 to intRangeSize Dim intRandomInteger ' Our final result - random integer to return dim randnum Response.Redirect("../default.asp") With Response .Write "
" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "
" & Lang_GBTitle & "
" & vbCrLf End With Dim formError, Name, Email, Ip, Homepage, Entry, formMode, X, str, vbCr Const adOpenKeyset = 1 Const adLockOptimistic = 3 If Request.Form("send") <> "" Then formError = "" Name = Request.Form("Name") Email = Request.Form("Email") IP = Request.ServerVariables("REMOTE_ADDR") Entry = Request.Form("Entry") Entry = Replace(Entry,str,str) Entry = Replace(Entry,vbCr,vbCr) Homepage = Request.Form("Homepage") If Len(Name) = 0 Then formError = Lang_Error2 ElseIf validateEmail(Email) = False Then formError = Lang_Error3 ElseIf Len(Entry) = 0 Then formError = Lang_Error4 Elseif Len(Homepage) = 0 then Homepage = "X" End If If Len(formError) = 0 Then %> <% Dim Validated_Form Dim IsOnBlackList Set rs = Server.CreateObject("ADODB.RecordSet") strSQL = "Select IP from bl where IP='" & IP & "'" rs.Open strSQL, Connect, adOpenKeyset, adLockOptimistic If rs.EOF then IsOnBlackList=false else IsOnBlackList=true end if rs.Close if instr(1,email,"@cashette.com")=0 and _ instr(1,email,"@gawab.com")=0 and _ instr(1,email,"@yandex.ru")=0 and _ instr(1,email,"@mail.ru")=0 then ' check domain blacklist!! if not IsOnBlackList and dhCountIn(Entry,"http",false)<2 and dhCountIn(Entry,"=2 or dhCountIn(Entry,"0 or dhCountIn(Entry,"http://google.us",false)>0 then ShowThanks else formError = "" & "You IP-Address is on the blacklist" & "
" formMode = "error" end if end if else end if else formError = "" & formError & "
" formMode = "error" End If else Set rs = Server.CreateObject("ADODB.RecordSet") strSQL = "Select IP from bl where IP='" & Request.ServerVariables("REMOTE_ADDR") & "'" rs.Open strSQL, Connect, adOpenKeyset, adLockOptimistic If rs.EOF then IsOnBlackList=false else IsOnBlackList=true With response .Write("

Your IP address " & Request.ServerVariables("REMOTE_ADDR") & " is on the blacklist
") .Write("Making an entry is therefore not allowed.

") & vbCrLf End With end if rs.Close Set rs = Nothing Connect.Close set Connect = Nothing End If 'Select FormMode / Auswahl Formular-Modus '1. bei Fehlern Select Case formMode Case "error" With Response .Write "
" & Lang_Error1 & "
" & formError & "" & vbCrLf %>
<% '.Write "" & vbCrLf .Write "
" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf %> <% .Write "
<% .Write "
" & Lang_Name & "
" & Lang_Email & "
" & Lang_Ip & "
" & Lang_Homepage & "http://
" & Lang_Entry & "
Verification code <% 'Randomize() ' Find range size 'intRangeSize = 5000 - 1000 + 1 ' Get a random number from 0 to the size of the range 'sngRandomValue = intRangeSize * Rnd() ' Center the range of possible random numbers over the desired result set 'sngRandomValue = sngRandomValue + intLowerBound ' Convert our value to an integer 'intRandomInteger = Int(sngRandomValue) randnum = RndStringGen(5,1,2) For intWriteDigitLoopCount = 1 to Len(randnum) 'Display the graphical hit count Response.Write("") Next %>       
" .Write "
" %>
" & vbCrLf .Write "
" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "
" & Lang_BackLink & "
" & vbCrLf End With '2. Normalanzeige Case Else With Response .Write "
" & vbCrLf %>
<% .Write "
" & vbCrLf .Write "" & vbCrLf if not IsOnBlackList then .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf %> <% .Write "
<% end if .Write "
" & Lang_Name & "
" & Lang_Email & "(only visible for the webmaster)
" & Lang_Homepage & "http://
" & Lang_Entry & "
(any language)
Verification code <% randnum = RndStringGen(5,1,2) For intWriteDigitLoopCount = 1 to Len(randnum) 'Display the graphical hit count Response.Write("") Next %>       
" %>
" & vbCrLf .Write "
" & vbCrLf .Write "" & vbCrLf .Write "" & vbCrLf .Write "
" & Lang_BackLink & "
" & vbCrLf End With End Select response.Write "
" & vbCrLf %>