Вся моя форма работает хорошо, единственное, чего я пытаюсь добиться, это объединить имя_фамиля с именем_фамиля, чтобы дать полное имя в заголовке электронного письма. Я использую PHPMailer. Это код, который я пытался использовать -
$firstname = $_POST["first_name"];
$lastname = $_POST["last_name"];
$fullname = $firstname . ' ' . $lastname;
$fullname = $_POST["name"];
$mail = new PHPMailer(TRUE);
$mail->From = $_POST["email"]; //Sets the From email address for the
message
$mail->FromName = $_POST["name"]; //Sets the From name of the message
$mail->AddAddress('timmy2872@gmail.com'); //Adds a "To" address
$mail->WordWrap = 50; //Sets word wrapping on the body of the
message to a given number of characters
$mail->IsHTML(true); //Sets message type to HTML
$mail->AddAttachment($path); //Adds an attachment from a path on the
filesystem
$mail->Subject = 'Employer Application Form details'; //Sets the
Subject of the message
$mail->Body = $message; //An HTML or plain text message body
if($mail->Send()) //Send an Email. Return true on success or
false on error
Кто-нибудь может увидеть, что я делаю неправильно?