Navigazione

    Privacy - Termini e condizioni
    © 2020 Search On Media Group S.r.l.
    • Registrati
    • Accedi
    • CATEGORIES
    • Discussioni
    • Non letti
    • Recenti
    • Hashtags
    • Popolare
    • Utenti
    • Stream
    • Interest
    • Categories
    1. Home
    2. piero.53
    3. Post
    P

    piero.53

    @piero.53

    • Profilo
    • Chi segue 0
    • Da chi è seguito 0
    • Discussioni 2
    • Post 4
    • Migliore 0
    • Gruppi 0
    Iscrizione Ultimo Accesso
    Località torino Età 72
    0
    Reputazione
    4
    Post
    0
    Visite al profilo
    0
    Da chi è seguito
    0
    Chi segue
    User Newbie

    Post creati da piero.53

    • RE: Dove ho sbagliato?

      @MenteLibera,
      ho provato ma la risposta è stata:

      Microsoft VBScript compilation error '800a0401'

      Expected end of statement
      /Login.asp, line 9
      conn.Open "driver={Microsoft Access Driver (*.mdb)}";dbq="&Server.MapPath("login.mdb")&"";
      che significa

      Microsoft VBScript errore di compilazione '800a0401 '
      Prevista fine istruzione
      / Login.asp, linea 9
      conn.Open "Driver = {Microsoft Access Driver (*. mdb)}"; DBQ = "& Server.MapPath (" login.mdb ") &" ";

      postato in Coding
      P
      piero.53
    • RE: Dove ho sbagliato?

      .....purtroppo anche spostando l'ultimo punto e virgola tra le ultime virgolette il risultato non cambia.
      Grazie comunque

      postato in Coding
      P
      piero.53
    • Dove ho sbagliato?

      Prima del restyling funzionava tutto, ora non riesco più ad accedere alle pagine riservate.

      Questi i dati inseriti:

      Caratteristiche del db:
      Login.mdb

      Tabella: utenti

      Campi: UserID e Password

      • Il form è situato in pagina index non protetta *
        [HTML]<td style="width: 265px;" class="style56">UserID:<br />

      <input name="txtUserID" style="width: 190px;" type="UserID" /><br />
       </td>
      </tr>
      <tr>

      <td style="width: 265px;" class="style56">
      Password:
      <input name="txtPassword" maxlength="4" style="width: 187px;" type="Password" />
      </td>
      </tr>
      <tr>
      <td style="width: 265px;" class="style57">
      input name="Submit" value="Invia" style="width: 91px;" type="submit" />
      </td>
      [/HTML]

      Logon.asp

      <%
      
      Dim UserID
      Dim Password
      UserID = Replace(Request.Form("UserID"), "'", "''")
      Password = Replace(Request.Form("Password"), "'", "''")
       
      Dim cn
      Set cn = Server.CreateObject("ADODB.Connection")
      cn.Open "driver={Microsoft Access Driver (*.mdb)};dbq="& Server.MapPath("login.mdb/utenti")&"";
      
      Dim sql
      
      sql = "SELECT ID FROM utenti WHERE UserID LIKE'" &UserID& "' AND Password='" &Password& "'"
      
      Dim rs
      
      Set rs = cn.Execute(sqlstmt, rowsupdated)
       
      Dim autenticato
      if rs.eof then
      autenticato = false
      else
      autenticato = true
      end if
      rs.Close
      cn.Close
      Set rs = Nothing
      Set cn = Nothing
       
      if autenticato = true then
      
      Session("Autenticato") = "OK"
      Response.Redirect("homapage.html")
      else
      Response.Redirect("login.html")
      end if
      %>
      
      

      A questo punto dovrebbe aprirmi la pagina protetta :homepage.html
      Invece risponde

      Microsoft VBScript compilation error '800a0401'
      Expected end of statement
      /Login.asp, line 9
      cn.Open "driver={Microsoft Access Driver (*.mdb)};dbq="& Server.MapPath("login.mdb/utenti")&"";

      Dove ho sbagliato? Grazie per l?aiuto.

      postato in Coding
      P
      piero.53
    • Buongiorno a tutti

      Buongiorno a tutti, sono Piero ed ho realizzato un piccolo sito per un'associazione di volontariato di cui faccio parte, sono qui in cerca di informazioni e aiuti per imparare e far crescere il sito.
      A presto.
      Piero

      postato in Presentati alla Community
      P
      piero.53