Guest User

Untitled

a guest
Dec 14th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. <form action="index.php" method="POST" enctype="multipart/form-data">
  2. Choose a file to upload: <input name="uploadedfile" type="file" />
  3. <input type="submit" value="Upload File" name="uploadedfile" />
  4. </form>
  5.  
  6. $imageinfo = getimagesize($_FILES['uploadedfile']['tmp_name']);
  7. if($imageinfo['mime'] != 'image/gif' && $imageinfo['mime'] != 'image/gif') {
  8. echo "Sorry, we only accepg GIF images";
  9. exit;
  10. }
  11.  
  12. ; Maximum allowed size for uploaded files.
  13. ; http://php.net/upload-max-filesize
  14. upload_max_filesize = 2000M
Add Comment
Please, Sign In to add comment