Popular posts from this blog
Image Upload PHP Core or OOPs
'jobseeker_photo' is the name of the input $file = $FILES['jobseeker_photo']; $fileName = $_FILES['jobseeker_photo']['name']; $fileTmpName = $_FILES['jobseeker_photo']['tmp_name']; $fileSize = $_FILES['jobseeker_photo']['size']; $fileError = $_FILES['jobseeker_photo']['error']; $fileType = $_FILES['jobseeker_photo']['type']; $fileExt = explode('.', $fileName); $fileActualExt = strtolower(end($fileExt)); $allowed = array('jpg', 'jpeg', 'png'); if(in_array($fileActualExt, $allowed)) { if($fileError === 0){ if($fileSize < 1000000) { $fileNameNew = uniqid('', true).".".$fileActualExt; $fileDestination = 'uploads/'.$fileNameNew; move_u
Comments
Post a Comment