php – Why is the array $ _FILES ['input name'] ['name'] empty?-ThrowExceptions

Exception or error:

I am trying to send a picture to the mail using the PHPMailer framework.
The phpdfw234 file is sent as an oh (for example), but there is no picture. I realized that the problem is $ _FILES [‘input name’] [‘name’].

$mail->addAttachment($_FILES['upload']['tmp_name'], $FILES['upload']['name']);

How to solve:

Leave a Reply

Your email address will not be published. Required fields are marked *