![]() |
Show 150 posts per page |
.dsy:it. (http://www.dsy.it/forum/)
- Tech (http://www.dsy.it/forum/forumdisplay.php?forumid=189)
-- [php] problema con caricamento immagini (http://www.dsy.it/forum/showthread.php?threadid=26455)
[php] problema con caricamento immagini
PHP:
/*absolutepath è la cartella dove caricare il file (esempio ./img), $file è
lavariabile proveniente dalla form e $filename il nome del file sul server*/
function caricaImmagine($absolute_path, $file, $nome_file){
$dir = "dir";
$file_name=$nome_file.".jpg";
if ($file != "")
{
if (file_exists("$absolute_path/$file_name"))
{
die("errore2: Un file con lo
stesso nome è già online, RINOMINARLO e inviarlo nuovamente");
}
@copy($file, "$absolute_path/
$file_name") or die("errore4: Problemi sul server... riprova più tardi o scrivici
una email");
return 1;
}
else
{
//die("errore5: Non hai selezionanto
nessun file!!!");
return 0;
}
}
__________________
msn Messenger: giamma80 at tiscali.it
ATHENA !
Come le carichi? Form o altro?
__________________
?
Originally posted by yeah
Come le carichi? Form o altro?
__________________
msn Messenger: giamma80 at tiscali.it
ATHENA !
dovresti contattare il dominio e farti dare spiegazioni sul codice di errore. problemi sul server mi sembra un pò generico..
__________________
"D.U.M.B. everyone's accusing me" - Pinhead
Scusa, avevo letto errore404, non errore4
Cmq usi da qualche parte move_uploaded_file()?
__________________
?
| All times are GMT. The time now is 22:44. | Show all 5 posts from this thread on one page |
Powered by: vBulletin Version 2.3.1
Copyright © Jelsoft Enterprises Limited 2000 - 2002.