salve, ho una pagina login che in locale funziona in remoto no, mi da il seguente errore:
ADODB.Recordset error '800a0bb9'
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
/login.asp, line 14
ho letto altri 3d ma non riesco a venirne fuori...
vi posto il codice di login.asp
la riga 14 è:codice:<%@LANGUAGE="JAVASCRIPT" CODEPAGE="1252"%> <% // *** Validate request to log in to this site. var MM_LoginAction = Request.ServerVariables("URL"); if (Request.QueryString!="") MM_LoginAction += "?" + Server.HTMLEncode(Request.QueryString); var MM_valUsername=String(Request.Form("nome")); if (MM_valUsername != "undefined") { var MM_fldUserAuthorization=""; var MM_redirectLoginSuccess="riservata.asp"; var MM_redirectLoginFailed="errore.asp"; var MM_flag="ADODB.Recordset"; var MM_rsUser = Server.CreateObject(MM_flag); MM_rsUser.ActiveConnection = MM_miaConnessione2_STRING; MM_rsUser.Source = "SELECT nome, password"; if (MM_fldUserAuthorization != "") MM_rsUser.Source += "," + MM_fldUserAuthorization; MM_rsUser.Source += " FROM utenti WHERE nome='" + MM_valUsername.replace(/'/g, "''") + "' AND password='" + String(Request.Form("password")).replace(/'/g, "''") + "'"; MM_rsUser.CursorType = 0; MM_rsUser.CursorLocation = 2; MM_rsUser.LockType = 3; MM_rsUser.Open(); if (!MM_rsUser.EOF || !MM_rsUser.BOF) { // username and password match - this is a valid user Session("MM_Username") = MM_valUsername; if (MM_fldUserAuthorization != "") { Session("MM_UserAuthorization") = String(MM_rsUser.Fields.Item(MM_fldUserAuthorization).Value); } else { Session("MM_UserAuthorization") = ""; } if (String(Request.QueryString("accessdenied")) != "undefined" && false) { MM_redirectLoginSuccess = Request.QueryString("accessdenied"); } MM_rsUser.Close(); Response.Redirect(MM_redirectLoginSuccess); } MM_rsUser.Close(); Response.Redirect(MM_redirectLoginFailed); } %> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>login</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> </p> <form name="form1" method="POST" action="<%=MM_LoginAction%>"> <div align="left"> <table width="100%" border="0" cellspacing="0" cellpadding="5"> <tr> <td width="11%">Username:</td> <td width="89%"><input name="nome" type="text" id="nome"></td> </tr> <tr> <td>Password: </td> <td><input name="password" type="text" id="password"></td> </tr> <tr> <td></td> <td><input type="submit" name="Submit" value="Entra"></td> </tr> </table> </div> </form> </p> </body> </html>
vi posto anche la pagina di connessione al db:codice:MM_rsUser.ActiveConnection = MM_miaConnessione2_STRING;
se accedo alla pagina login.asp i campi nome e password li vedo, ma al momento di fare submit mi da quell'errore..codice:<% // FileName="Connection_ado_conn_string.htm" // Type="ADO" // DesigntimeType="ADO" // HTTP="true" // Catalog="" // Schema="" var MM_miaConnessione2_STRING = "DRIVER={Microsoft Access Driver (*.mdb)};" & "DBQ=(Server.MapPath(mdb-databse\db-locali.mdb))" %>
Spero che qualcuno mi possa aiutare..
grazie 1000

Rispondi quotando

