php.de

Zurück   php.de > Webentwicklung > PHP Einsteiger > PHP Tipps 2009

 
 
LinkBack Themen-Optionen Thema bewerten
Alt 13.01.2009, 16:39  
Neuer Benutzer
 
Registriert seit: 21.12.2008
Beiträge: 18
waldsee befindet sich auf einem aufstrebenden Ast
Standard Foto upload Problem

Ich habe ein Problem über Foto - upload, ich habe in einer phpdatei folgende Code geschrieben:
PHP-Code:
<h1>Upload new news files</h1>
  <
form enctype="multipart/form-data" action="upload.php" method="POST">
     <
input type="hidden" name="MAX_FILE_SIZE" value="1000000">
     
Upload this file: <input name="userfile" type="file"
     <
input type="submit" value="Send File">
  </
form
Und außdem habe ich in der upload.php das folgende Code geschrieben:
PHP-Code:
<?php

$uploaddir 
'/var/www/uploads/';
$uploadfile $uploaddir basename($_FILES['userfile']['name']);

if (
move_uploaded_file($_FILES['userfile']['tmp_name'], $uploadfile)) {
    echo 
"File is valid, and was successfully uploaded.\n";
} else {
    echo 
"Possible file upload attack!\n";
}

echo 
'Here is some more debugging info:';
printf($_FILES);
?>
Ich möchte ein Foto in der upload.php anzeigen.aber es gibt nichts darin.
Ich weiß nicht warum, und hoffe Hilfe. Danke.
waldsee ist offline  
Sponsor Mitteilung
PHP Code Flüsterer

Registriert seit: 21.08.2005
Beiträge: 4682
PHP-Kenntnisse:
Fortgeschritten

Alt 13.01.2009, 17:10  
moderatives Dielektrikum
 
Benutzerbild von nikosch
 
Registriert seit: 21.05.2008
Beiträge: 35.989
PHP-Kenntnisse:
Fortgeschritten
nikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunftnikosch hat eine strahlende Zukunft
Standard

Zitat:
aber es gibt nichts darin.
Was soll das heißen? Worin?
__________________
--
One pixel is still too big. Please make it smaller. ASAP.

Initiative Mittelstand.
Die wichtigste Gestaltungsregel im Screendesign ist Pi mal Daumen des Arbeitgebers.
--
nikosch ist offline  
Alt 13.01.2009, 17:31  
PTC
Erfahrener Benutzer
 
Benutzerbild von PTC
 
Registriert seit: 27.10.2007
Beiträge: 1.708
PHP-Kenntnisse:
Anfänger
PTC ist einfach richtig nettPTC ist einfach richtig nettPTC ist einfach richtig nettPTC ist einfach richtig nett
Standard

Hast du überhaupt eine Datei im Browser über das Formular hochgeladen?
PTC ist offline  
 


Themen-Optionen
Thema bewerten
Thema bewerten:

Forumregeln
Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are an
Gehe zu

Ähnliche Themen
Thema Autor Forum Antworten Letzter Beitrag
[Erledigt] Problem bei datei upload mit $_FILE serious-cool PHP Tipps 2008 12 25.11.2008 20:11
Problem Upload mehrere Dateien und schreiben in DB Lapje PHP Tipps 2008 1 22.10.2008 13:12
[Erledigt] Upload problem Chewy PHP Tipps 2008 4 06.08.2008 11:33
[Erledigt] Problem mit Foto Upload von Hochformat auf Querformat KokosDesign PHP Tipps 2008 5 22.07.2008 16:52
datei upload problem thecracked PHP Tipps 2008 5 11.07.2008 06:23
Problem mit File Upload b++ PHP Tipps 2006 2 26.04.2006 20:35
Upload problem m-elssner PHP Tipps 2007 4 13.12.2005 22:02
Problem mit File Upload PHP Tipps 2007 3 06.11.2005 23:39
upload zum xten mal aber evt mal n anderes problem mqs PHP Tipps 2004-2 2 14.12.2004 20:29
[Erledigt] PHP Upload (Master Value/Local Value Problem) PHP-Fortgeschrittene 5 23.11.2004 07:21
Problem bei upload (mit templates) PHP Tipps 2004 4 02.08.2004 12:01
problem mit normalem ftp upload! PHP Tipps 2004 4 30.07.2004 18:46
Upload problem -> unerklärliche fehlermeldung PHP Tipps 2004 9 19.07.2004 10:43
[Erledigt] Php skript upload problem! PHP Tipps 2004 2 30.06.2004 00:06
[Erledigt] altes neues problem von datei upload!!! PHP Tipps 2004 3 28.06.2004 19:06

Besucher kamen über folgende Suchanfragen bei Google auf diese Seite
fotoupload php, php fotoupload, php foto upload, photo upload.de

Alle Zeitangaben in WEZ +2. Es ist jetzt 20:07 Uhr.




Powered by vBulletin® Version 3.7.2 (Deutsch)
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
Aprilia-Forum, Aquaristik-Forum, Liebeskummer-Forum, Zierfisch-Forum, Geizkragen-Forum