Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $mail = new PHPMailer();
- $mail->CharSet = 'utf-8';
- $email_body = "";
- $email_body = $email_body . "<p>Имя:</p><h2>".$name."</h2><p>Телефон:</p><h2>".$phone."</h2><p>Email:</p><h2>".$email."</h2>";
- $uploadfile = tempnam(sys_get_temp_dir(), sha1($_FILES['file']['name']));
- $filename = $_FILES['myfile']['name'];
- if (move_uploaded_file($_FILES['file']['tmp_name'], $uploadfile)) {
- $mail->addAttachment($uploadfile, $filename);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement