codice:
if len(session("id_utente")) = 0 then
'Prelevo i dati dal pannello di Login
username = request("username")
password = request("password")
'Effettuo il controllo
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open ConString
bolFound = false
strsql = "select id, username, password from tbl_Clienti where username = '" & username & "' and password = '" & password & "'"
set rs = Conn.execute(strsql)
if not rs.eof then
session("id_utente") = rs("id")
bolFound = true
end if
rs.close
set rs = nothing
Conn.close
set Conn = nothing
if not bolFound then response.redirect ("login.asp")
end if
Roby