table = "adminsettings"; $node->select = "*"; $node->where = "where myoption = 'adminemail'"; $rowemail = $mysql->select_assoc($node); function clean_string($string) { $bad = array("content-type","bcc:","to:","cc:","href"); return str_replace($bad,"",$string); } $email_subject=$_POST['subject']; $email_from=$rowemail['optionvalue']; $email_to = $rowemail['optionvalue']; $email_message .= "Name: ".clean_string($_POST['name'])."\n"; $email_message .= "Email: ".clean_string($_POST['email'])."\n"; $email_message .= "web: ".clean_string($_POST['web'])."\n"; $email_message .= "Message: ".clean_string($_POST['message'])."\n"; //echo $email_message; // create email headers $headers = 'From: '.$email_to."\r\n". 'Reply-To: '.$email_from."\r\n" . 'X-Mailer: PHP/' . phpversion(); @mail($email_to, $email_subject, $email_message, $headers); $msg='Submitted Successfully'; } $node = new sqlNode(); $node->table = "contents"; $node->select = "*"; $node->where = "where content_type = 'Contact Us'"; $row_sel = $mysql->select_assoc($node); ?> <? echo $row_sel['title'];?>

Get in Touch