
ownyamama
Member

Feb 10, 2007, 8:55 AM
Post #1 of 1
(236 views)
Shortcut
|
|
Need help with upload script
|
Can't Post
|
|
Any one can make or edit the code to make so that when they upload it goes to a page and tells them the link to there image and put the file types that are aloud to be uploaded and heres the upload.php page code :
<?php if(!(copy($_FILES['userfile']['tmp_name'], "img1/" . $_FILES['userfile']['name']))) die("Sorry this file is the wrong type or to big"); echo "Upload Complete!"; ?>
And heres the form
<form action="upload.php" method="post" enctype="multipart/form-data"> <input type="hidden" name="MAX_FILE_SIZE" value="1000"> Select a file <input type="file" name="userfile"><br> <input type="submit" value="Upload!">
|