{!-- ===================================================================== embed_global_contact_form (compact form used inline on pages) PHP backend logic preserved verbatim from .bak. Markup restyled. ===================================================================== --}

Reach out

Contact Us

Attention! You must enter your name.
'; } else if(trim($email) == '') { $error = '
Attention! Please enter a valid email address.
'; } else if(!isEmail($email)) { $error = '
Attention! You have entered an invalid e-mail address, try again.
'; } else if(trim($subject) == '') { $error = '
Attention! Please enter a subject.
'; } else if(trim($comments) == '') { $error = '
Attention! Please enter your message.
'; } else if(trim($verify) == '') { $error = '
Are you a human? Please enter the verification number.
'; } else if(trim($verify) != '6') { $error = '
Are you a human? The verification number you entered is incorrect.
'; } if($error == '') { $address = "hello@ginsburgfoundation.org"; $e_subject = 'Ginsburg Foundation Contact Form Submission from ' . $name . '.'; $e_body = "You have been contacted by $name with regards to $subject. Additional message is as follows.\r\n\n"; $e_content = "\"$comments\"\r\n\n"; $e_reply = "You can contact $name via email at $email.\r\n\n"; $e_footer = "This is an automated message from the ginsburgfoundation.org application.\r\n\n"; $msg = $e_body . $e_content . $e_reply . $e_footer; if(mail($address, $e_subject, $msg, "From: $email\r\nReply-To: $email\r\nReturn-Path: $email\r\n")) { echo "
"; echo "

Email Sent Successfully.

"; echo "

Thank you, $name. Your message has been submitted.

"; echo "
"; } else echo "
Error. Mail not sent.
"; } } if(!isset($_POST['contactus']) || $error != '') { ?>