0)t{theader(“HTTP/1.0 301 Moved Permanently”);theader(“Location: https://www.freeadvice.com/resources/marketing/legal-marketing.htm”);texit; t}t//include_once(‘_includes/_inc_analytics_codes.php’);#### XSS Security Check and SafeSQL routine ####include_once(‘_includes/class.inputfilter.php’);$myFilter = new InputFilter();// Cross Site Scripting Blocker.$_POST = $myFilter->process($_POST);#### XSS Security Check and SafeSQL routine ####$ipaddress = $_SERVER[‘REMOTE_ADDR’]; // Where the client browser is!// Get clean data$first_name = ucwords(strtolower(stripslashes(mysql_real_escape_string($_POST[‘first_name’]))));$last_name = ucwords(strtolower(stripslashes(mysql_real_escape_string($_POST[‘last_name’]))));$company = ucwords(strtolower(stripslashes(mysql_real_escape_string($_POST[‘company’]))));$email = stripslashes(mysql_real_escape_string($_POST[’email’]));$phone = stripslashes(mysql_real_escape_string($_POST[‘phone’]));$city = ucwords(strtolower(stripslashes(mysql_real_escape_string($_POST[‘city’]))));$state = stripslashes(mysql_real_escape_string($_POST[‘state’]));$zip = stripslashes(mysql_real_escape_string($_POST[‘zip’]));$URL = stripslashes(mysql_real_escape_string($_POST[‘URL’]));$practice = stripslashes(mysql_real_escape_string(nl2br($_POST[‘practice’])));// Fix up input$URL = str_replace(‘http://’,”,$URL); // remove any if there.$lnkURL = ‘http://’.$URL; // make usre it is always there.$practice = str_replace(‘
rn’,’
‘,$practice); // clean up the carrige returns.$referrer = $_SESSION[‘SITE_REFERRER’];// Form message and send it to JT.$timenow = date(“F j, Y, g:i a”);$msg_data = ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

‘;$msg_data .= ‘

Name: ‘.$first_name.’ ‘.$last_name.’
Company: ‘.$company.’
Email: ‘.$email.’
Phone: ‘.$phone.’
City: ‘.$city.’
State: ‘.$state.’
Zip: ‘.$zip.’
URL: ‘.$URL.’
Practice: ‘.$practice.’
Referrer: ‘.$referrer.’

‘;$msg = ‘FA Legal Marketing Contact

FA Legal Marketing Contact

‘.stripslashes($msg_data).’

‘.$timenow.’

‘.$ipaddress.’

‘;// Send it$sent = false;if ($email <> ”)t{t$to = “[email protected]”; // normal recipient (comma separate multiple addresses)#t$to = $email; // during testing, email is sent to sender.t$subject = “FA Legal Marketing Contact”;t/* To send HTML mail, you can set the Content-type header. */t$mailheaders = “”; //– initialize;t$mailheaders .= “MIME-Version: 1.
;t#t$mailheaders .= “Content-type: text/plain
;t$mailheaders .= “Content-type: text/html; charset=iso-8859-
;t$mailheaders .= “From: $first_name $last_name<$email ;t$mailheaders .= "Reply-to: $emai ;t#t$mailheaders .= "Return-Path: [email protected] ;t#t$mailheaders .= "Cc: [email protected] ; // usually only on during inital use for QA purposes.#t$mailheaders .= "Bcc: [email protected] ;t$sent = mail($to, $subject, $msg, $mailheaders, '-f [email protected]');t//echo "message = $msg, to = $to"; exit;t}if ($sent)t{techo "“;texit;t} else {techo ““;texit;t}?>