PDA

View Full Version : my simple php upload script is not working



csanpedro
04-09-2008, 01:16 AM
hi there!

my simple picture upload scriptis not working.. please help me

here is the uploader.html form:


<form action="uploader.php" method="post" enctype="multipart/form-data">
<label>Screenshot Upload</label>
<input name="txtScreen" type="file"/>
<input name="Submit" type="submit" value="Upload"/>
</form>


here is the uploader.php script from uploader.html form:


//uploading of screenshot
$target_path = "photos/"; //destination folder
$target_path = $target_path . $_FILES["txtScreen"]["name"];
move_uploaded_file($_FILES['txtScreen']['tmp_name'], $target_path);

James
04-15-2008, 05:43 AM
Got a live example of this?

stuffradio
04-17-2008, 11:33 PM
It looks fine to me, is the folder you're putting the files in CHMOD 777?