Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $GetPost = filter_input_array(INPUT_POST,FILTER_DEFAULT);
- $Erro = true;
- $Tipo = $GetPost['tipo'];
- $Nome = $GetPost['nome'];
- $Email = $GetPost['email'];
- $Telefone = $GetPost['telefone'];
- $Cargo = $GetPost['cargo'];
- $Curriculo = $_FILES['curriculo'];
- $Mensagem = $GetPost['mensagem'];
- include_once 'PHPMailer/class.smtp.php';
- include_once 'PHPMailer/class.phpmailer.php';
- $Mailer = new PHPMailer;
- $Mailer->CharSet = "utf8";
- $Mailer->SMTPDebug = 1;
- $Mailer->FromName = "Jogo Digital";
- $Mailer->From = "leo@jogo.digital";
- $Mailer->AddAddress("renata@jogo.digital");
- $Mailer->IsHTML(true);
- $Mailer->Subject = "Novo currículo \"Trabalhe Conosco\" - {$Nome}";
- $Mailer->AddAttachment($Curriculo);
- $Mailer->Body = "
- Novo currículo enviado por {$Nome}<br />
- Tipo: {$Tipo}<br /><br>
- <b>Dados:</b><br /><br>
- Email: {$Email}<br>
- Telefone: {$Telefone}<br>
- Cargo: {$Cargo}<br>
- Mensagem: {$Mensagem}<br>
- Curriculo: {$Curriculo['name']}
- ";
- if($Mailer->Send()){
- $Erro = false;
- }
- var_dump($Erro);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement