<?phpif(isset($_POST['Submit']) && isset($_POST['name']) && isset($_POST['email'])){ echo "Your information has been sent to the group, somebody will contact you. Thanks!\n"; $message = ''; $message .="Hello Rachel,\n"; $message .="Somebody has sent you an email from the Young Professionals Website interested in joining or recieving more information about the Young Professionals.\n"; $message .="The following information is the information they filled out in the form:\n"; $message .="Name = {$_POST['name']}\n"; $message .="Phone = {$_POST['phone']}\n"; $message .="Email = {$_POST['email']}\n"; $message .="Comments:\n"; $message .="{$_POST['comment']}\n"; $message .="Thanks,\n"; $message .="The Young Professional Website\n"; mail('theemail@addressiuse.com', 'Young Professionals Interest', $message);} else {?><div id="joinform"><form method="POST" action="<?php echo htmlspecialchars($_SERVER['PHP_SELF']); ?>">Name:<input type="text" name="name"><br />Organization:<input type="text" name="Organization"><br />Phone Number:<input type="text" name="Phone"><br />Email Address:<input type="text" name="Email"><br />Comment:<br /><input type="text" name="comment"><br /><input type="submit" name="Submit"><br /></form></div><?php}?>