I am having some trouble with setting up a mail form for my site. Currently, when I press submit on the form, the email that gets sent to me only shows the text portion of it and it does not show the variable! So in my email it would only show "This message is from"
I am fairly new to PHP - hopefully someone can take a look and maybe point out something I am not getting??
Thanks!
<?
if(isset($_POST['message']) && ($_POST['message'] != '')){
$name = $_POST["name"];
$subject = "New Request";
$recipient = "my@email.com";
$message = $_POST["message"];
$mailBody = 'This message is from $name \n $message;
mail($recipient, $subject, $mailBody);
}
?>