%@ Language=VBScript %>
<%
' ///////////////////////////////////////////////////////
' // Dimac CMS
' // Copyright 2004-2008 Dimac Development AB, Sweden
' // www.Dimac.net
' //
' // NOTE:
' // You are not allowed to remove this
' // Copyright information without written
' // permission from Dimac Development.
' ///////////////////////////////////////////////////////
' -------------------------------------------------------
' -- Global variables
' -------------------------------------------------------
Dim Conn, Rs, SQL , ResultText
vEmail = FF(Request.Form("Email").item)
vPassword = FF(Request.Form("Password").item)
' ///////////////////////////////////////////////////////
Sub UpdateUserStatus(vUserID)
Set Conn2 = Server.CreateObject("ADODB.Connection")
Set Rs2 = Server.CreateObject("ADODB.Recordset")
Conn2.Open GetConStr ("..\..\SiteResources\Data\")
SQL2 = "SELECT LoginCount From Members WHERE ID= " & vUserID
set Rs2 = Conn2.Execute(SQL2)
SQL2 = " UPDATE Members SET "
SQL2 = SQL2 & " LastLoggin = '" & Year(Now) & "-" & FixNumber(Month(Now)) & "-" & FixNumber(Day(Now)) & " " & FormatDateTime(Now, vbShortTime) & "',"
SQL2 = SQL2 & " LoginCount = " & Cint(Rs2("LoginCount").value) + 1
SQL2 = SQL2 & " WHERE ID = " & vUserID
Set Rs2 = Conn2.Execute(SQL2)
Set Rs2 = Nothing
Set Conn2 = Nothing
End Sub
' ///////////////////////////////////////////////////////
Set Conn = Server.CreateObject("ADODB.Connection")
Set Rs = Server.CreateObject("ADODB.Recordset")
Conn.Open GetConStr ("..\..\SiteResources\Data\")
SQL = "SELECT * From Members "
SQL = SQL & "WHERE Email = '" & vEmail & "' "
SQL = SQL & "AND MemberPassword = '" & vPassword & "'"
set Rs = Conn.Execute(SQL)
IF RS.eof THEN
Session("Member_Valid") = "FALSE"
ResultText = "
"
ResultText = ResultText & " Email or password is incorrect !! |
You have logged in sucessfully. " ResultText = ResultText & " Please click the following link to active your login settings. " ResultText = ResultText & "Click here to activate. |
"
ResultText = ResultText & " Your account is not active or pending !! !! |