I have a form with multiple check boxes. once the form is complete it is sending a email with php. I'm trying to have a feature in the subject bar so it displays
Subject: Option 1
Subject: Option 2
Subject: Option 1 and Option 2
if (empty($_POST["CheckboxGroup1"]) || empty($_POST["CheckboxGroup2"])) {
"$displaythis = '';"; }
else { "$displaythis = ' and ';"; }
Something is wrong but I don't know where. Any tips? Thanks
$emailSubject = $_POST['CheckboxGroup1'] . $displaythis . $_POST['CheckboxGroup2'];