Salve!
Ho un problemino su una pagina Asp Ocean12 ASP Mailing List Manager v1.06 (sistema di newsletter)
In pratica ho apportato alcune piccole modifiche sulla pagina di avvenuta registrazione, a ad oggi ho notato un bug.
In pratica cliccando su INVIA e lasciando il campo Email vuoto l'utente viene inserito ugualmente nel database della newsletter.
ho notato un if e un else. In pratica dice che SE si lascia il campo vuoto (esempio) fa una determinata azione, ma non so come reindirizzarlo su un altra pagina...
Qualcuno sa smanettarci sopra??
<% Dim useraction Dim Email Dim Action Dim SQL Email = lcase(request.form("Email")) useraction = request.form("Join_Quit") set RS = server.createobject("adodb.recordset") SQL = "SELECT * FROM List WHERE Email = '" & Email & "'" RS.open SQL, conn, 2, 2
If (request("Email") = "empty") Then Action = "Invalid Email Address. Please Try again." Else select case useraction case "Join" if RS.bof and RS.eof then RS.addnew RS("Email") = request("Email") RS("Name_Last") = request("Name_Last") RS("Name_First") = request("Name_First") RS("Date_In") = Date RS.update Action = "Thank you for joining." else Action = "You are already a member." end if case "Quit" if RS.bof and RS.eof then Action = "You are not member." else sql2="DELETE FROM List WHERE Email = '" & Email & "'" conn.execute(sql2) Action = "You have been removed." end if end select End If RS.close set RS = nothing %>
<html> <head> <title>Attendere</title> <script language="javascript"> </script> </head> <body onload="setTimeout('goURL()', 1000);"> Redirect in corso... </body> </html>

Rispondi quotando