Visualizzazione dei risultati da 1 a 3 su 3

Discussione: problema upload baol

  1. #1
    Utente di HTML.it L'avatar di miki.
    Registrato dal
    Oct 2004
    Messaggi
    1,918

    problema upload baol

    ammetto che ho preso lo script così senza ragionarci tanto.
    Il fatto è che non mi salva il file, e non da errore.
    Il codice è cosi.


    <%
    If Request("Upload")="1" then
    Dim oUpload
    Set oUpload = new cUpload
    oUpload.Load()
    oUpload.UploadOnly "Images"
    oUpload.SaveAs "Pippo.mp3"
    oUpload.SaveAll
    Set oUpload=Nothing
    response.Write("prova")
    end if
    %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <title>Documento senza titolo</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    </head>

    <body>
    <form method="Post" enctype="multipart/form-data" action="insert_news.asp?upload=1">
    File : <input type="file" name="Campo1">

    Nome immagine: <input type="text" name="nome_img">

    <input type="submit" name="Enter">

    </form>
    </body>
    </html>
    You cannot discover new oceans unless you have the courage to lose sight of the shore

    Caro Dio, quando nelle preghiere ti chiedevo di far morire quel pedofilo truccato, liftato,mentalmente disturbato e di colore indefinibile, non intendevo Michael Jackson.

  2. #2
    Utente di HTML.it L'avatar di Baol74
    Registrato dal
    Jul 2002
    Messaggi
    2,004
    Qualche modifica, con questo codice puoi caricare solo immagini:
    codice:
     
    <% 
    If Request.QueryString("Upload")="1" then 
    Dim oUpload 
    Set oUpload = new cUpload 
    pUpload.SetPath "."
    oUpload.Load() 
    
    oUpload.UploadOnly "Images" 
    oUpload.SaveAs "Pippo.mp3" 
    response.Write"Il file è stato salvato"
    Set oUpload=Nothing 
    end if 
    %> 
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
    <html xmlns="http://www.w3.org/1999/xhtml"> 
    <head> 
    <title>Documento senza titolo</title> 
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> 
    </head> 
    
    <body> 
    <form method="Post" enctype="multipart/form-data" action="insert_news.asp?upload=1"> 
    File : <input type="file" name="Campo1">
     
    Nome immagine: <input type="text" name="nome_img">
     
    <input type="submit" name="Enter"> 
    
    </form> 
    </body> 
    </html>

  3. #3
    Utente di HTML.it L'avatar di miki.
    Registrato dal
    Oct 2004
    Messaggi
    1,918
    che testa di cavolo che sono
    facevo le prove e non caricavo file immagini, idiota :rollo:

    scusa il disturbo
    You cannot discover new oceans unless you have the courage to lose sight of the shore

    Caro Dio, quando nelle preghiere ti chiedevo di far morire quel pedofilo truccato, liftato,mentalmente disturbato e di colore indefinibile, non intendevo Michael Jackson.

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.