note 88601 added to function.move-uploaded-file
| From: | omgmain at gmail dot com | Date: | Sat, 31 Jan 2009 04:23:05 +0000 |
| Subject: | note 88601 added to function.move-uploaded-file | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-150023@lists.php.net to get a copy of this message | ||
This function should run perfectly, but just in case there are errors, this should help.
1 : Check that the syntax is correct. Remember, lines end with ;
2 : Make sure that the file you're moving exists, and that the place you're writing to
is...well, writable. Sometimes, for instance with mac, they make the file so that it can only be
accessed by the system, and you. You need to make it available for everyone.
3 : Make sure that the file size of the file you're uploading is under the max upload size. You
can change the allowed file size on the php.ini file. The default value is 2M (M as in Megabytes).
Also make sure that uploading is allowed
---
If you don't have any errors, then give yourself a pat on the back. BUT, to make your script
more secure, put in your file:
str_replace('.', '', $_FILES['file name']['name']);
str_replace('/', '', $_FILES['file name']['name']);
Replace file name with the file name, and you're good to go!
----
Server IP: 208.69.120.35
Probable Submitter: 76.201.169.81
----
Manual Page -- http://www.php.net/manual/en/function.move-uploaded-file.php
Edit -- https://master.php.net/note/edit/88601
Del: integrated -- https://master.php.net/note/delete/88601/integrated
Del: useless -- https://master.php.net/note/delete/88601/useless
Del: bad code -- https://master.php.net/note/delete/88601/bad+code
Del: spam -- https://master.php.net/note/delete/88601/spam
Del: non-english -- https://master.php.net/note/delete/88601/non-english
Del: in docs -- https://master.php.net/note/delete/88601/in+docs
Del: other reasons-- https://master.php.net/note/delete/88601
Reject -- https://master.php.net/note/reject/88601
Search -- https://master.php.net/manage/user-notes.php