I have this code :
chmod('uploads', 0777);
$image = $_FILES['image']['tmp_name'];
$_FILES['image']['name'] = date('d-m-Y_H-i-s-') . rand(11111,99999) * rand(99999,11111) . rand(111,999) . $_FILES['image']['tmp_name'];
and this :
move_uploaded_file($_FILES['image']['tmp_name'], 'uploads/');
but when I run the code I get this error message:
Warning: move_uploaded_file(uploads/) [function.move-uploaded-file]: failed to open stream: Permission denied in D:\AppServ\www\tab\submit.php on line 51
Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move 'C:\Windows\Temp\php4D3.tmp' to 'uploads/' in D:\AppServ\www\tab\submit.php on line 51
How to fix it??