'; print_r($str); echo ''; } /*****************************************************************/ /******************** form is submitted ***************************/ if ($_POST['action'] == 'process'){ // validate required fields $missing = array(); // missing vals $err = array(); // merge all errs for display $aReq = explode(",",$_POST['areq']); foreach ($aReq as $r){ if (!$_POST[$r]){ $missing[] = ucfirst(str_replace("_"," ",$r )) . ' is required.'; } } if ($_POST['email'] && !isValidEmail($_POST['email']) ){ $err[] = 'Email is incorrectly formed.'; } // clean for email injection foreach( $_POST as $value ){ if( is_array($value) === false && strpos($value,'Content-Type:') !== FALSE ){ $spam = true; } } // get all errors and put them in one clean var for output $allErr = array_merge($missing,$err); $message = @implode('
',$allErr); // send email if (!$spam && !$message){ $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=ISO-8859-1\n"; $headers .= "From: ".$_POST['email'] ." \r\n"; $body = date('F j, Y h:i:s A'). '
' .chr(10); $body .= 'The following form has been submitted.

' .chr(10).chr(10); foreach ($_POST as $FormFieldName=>$FormFieldValue) { // dont send theses $skipArr = array ('action','areq','submit'); if (is_array($_POST[$FormFieldName])){ $FormFieldValue = @implode("
",str_replace("_"," ",$FormFieldValue)); } if (in_array($FormFieldName,$skipArr) === false){ if ($FormFieldValue) { $body .= ucwords(str_replace("_"," ",$FormFieldName)) . ': ' . $FormFieldValue. '
' .chr(10); } } } mail($to,$subject, $body, $headers); if ($cc){ // send a copy to.... mail($cc,$subject, $body, $headers); } $message = 'Thank you for your submission'; $success = true; } // end send mail } // end if process David Gaffney - Realtor

CONTACT DAVE

GET MORE INFORMATION FROM DAVE BY FILLING OUT THIS EASY EMAILABLE FORM.

Information provided by the consumer is only used for the purpose of responding to inquiries; it is never sold or shared.

FORM

I WANT TO SAVE TIME AND MONEY! I live near Columbia, MO, please sell my home!
Don't sign me up yet, but please help me determine the market value of my home.
Tell me about your marketing plan. How will you sell my home?
Help me sell For Sale by Owner.
Why Should I list with a Century 21 agent anyway?

buyer:
I WANT TO SAVE TIME AND MONEY! Sign me up and find me a home!
Why and how to pre-qualify.
Why should I sign a Buyer's Agency Agreement?
10 steps to buying a home.
I'll be new in Columbia, send me general info about home values there.
Send me information geared toward first-time homebuyers.

I would prefer this information
faxed
E-Mailed
put in an envelope with stamps
I desire a call to address more specific or other needs.

 

 

                           - CONTACT DAVE -                             icons CRS
real
Dave Gaffney - Licensed in Missouri - CoMo Realty
(573)443-6736 - Fax: 443-8188 - Email: dave@thebetteragent.net
Contents© 2010 David Gaffney
Gaffney & Associates