/* code no longer used. Redirected on 3/29/19 after it showed up in the error logs */ /* Redirect browser */ header("Location: https://www.digitalmusicservices.com/404.php"); /* Make sure that code below does not get executed when we redirect. */ exit; /* -------------------------- */ // include($Path."common/page_redirect.php"); // include("Debug2.php"); $Path = ""; $ERR = ""; // Get Path to ROOT Level unset($Path); $depth = substr_count($_SERVER['PHP_SELF'],"/"); while($depth > 1) {$Path .= "../"; --$depth;} unset($path); $path = $Path; $sendername = $_POST['sendername']; $senderemail = $_POST['senderemail']; $subject = $_POST['subject']; $note = $_POST['note']; // if Send Mail Button is pressed - send the mail if ($_POST['send'] == "Send Mail") { // ERROR TRAPPING =============================================== // Email Addr Trap - no @ in the field if (filter_var($senderemail, FILTER_VALIDATE_EMAIL)) {} else {$ERR = "ADDRfrom";} if($senderemail == "") { $ERR = "ADDRfrom"; } // Empty Required Field Trap if(($sendername == "") || ($note == "")) { $ERR = "Data"; } // Is HTML code in the "$note" field ? if(strlen($note) != strlen(strip_tags($note))) { $ERR = "html"; } // If NO ERRORS - Proceed to Send Email if ($ERR == "") { // SENDMAIL ===================================================== if ($subject == "") { $subject = "From DMS Website:"; } if ($subject != "") { $subject = "DMS: ".$subject; } $note = stripslashes($note); $sendername = stripslashes($sendername); $subject = stripslashes($subject); $signature = " ---------------------------------------- Digital Music Services www.digitalmusicservices.com"; mail ( "info@digitalmusicservices.com","$subject", "Name: ".$sendername . "\r\n" . "Email: ".$senderemail . "\r\n\r\n" . "Subject: ".$subject . "\r\n----------------------------------------\r\n" . $note . "\r\n" . $signature, "From: $senderemail\n" ); // Log this $LogEntry = "Email"; include ($Path."LogGen.php"); $ERR = "SENT"; } // RESULT MESSAGE ================================== // OnClick=\"Javascript:location.href='http://www.digitalmusicservices.com/Home.php';\" if ($ERR != "") {echo "
"; }
// SUCCESS: Email SENT
//$hidden = "1"; echo "Code: $ERR $hidden "; if (($ERR == "SENT") && ($hidden != "1")) {echo "
|