session_start(); $colname_Recordset1 = "1"; if (isset($_GET['rentalid'])) { $colname_Recordset1 = (get_magic_quotes_gpc()) ? $_GET['rentalid'] : addslashes($_GET['rentalid']); mysqli_select_db($Vacation,$database_Vacation); $query_Recordset1 = sprintf("SELECT * FROM rentals LEFT JOIN states ON rentals.rentalstatecode = states.statecode WHERE rentalid = %s", $colname_Recordset1); $Recordset1 = mysqli_query( $Vacation,$query_Recordset1) or die(mysqli_error()); $row_Recordset1 = mysqli_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysqli_num_rows($Recordset1); $FeaturedField = "featuredcityexpires"; $City = escapeDB($row_Recordset1['rentalcity'], $Vacation); $State = escapeDB($row_Recordset1['rentalstatecode'], $Vacation); $type = 'rental'; $rentals = $_POST['RentalIDs']; } if (isset($_GET['attractionid'])) { $colname_Recordset1 = (get_magic_quotes_gpc()) ? $_GET['attractionid'] : addslashes($_GET['attractionid']); mysqli_select_db($Vacation,$database_Vacation); $query_Recordset1 = sprintf("SELECT * FROM attractions LEFT JOIN states ON attractions.attractionstatecode = states.statecode WHERE attractionid = %s", $colname_Recordset1); $Recordset1 = mysqli_query( $Vacation,$query_Recordset1) or die(mysqli_error()); $row_Recordset1 = mysqli_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysqli_num_rows($Recordset1); $FeaturedField = "featuredcityexpires"; $City = escapeDB($row_Recordset1['attractioncity'], $Vacation); $State = escapeDB($row_Recordset1['attractionstatecode'], $Vacation); $type = 'attraction'; $rentals = $_POST['RentalIDs']; } mysqli_select_db($Vacation,$database_Vacation); if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) { if(($_SESSION['security_code'] == $_POST['security_code']) && (!empty($_SESSION['security_code'])) ) unset($_SESSION['security_code']); else $errormsg[] = "You did not enter the correct security code."; if ($_POST['HowMany'] > 10) $errormsg[] = "You may select only 10 rentals to email."; if (strlen($_POST["firstname"]) < 2) $errormsg[] = "Please provide us with your first name."; if (strlen($_POST["lastname"]) < 2) $errormsg[] = "Please provide us with your last name."; if (strlen($_POST["email"]) < 8) $errormsg[] = "Please provide us with your email address."; if (isset($errormsg)){ $_POST["MM_insert"] = ""; unset($_POST["MM_insert"]); } } $editFormAction = $_SERVER['PHP_SELF']; if (isset($_SERVER['QUERY_STRING'])) { $editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']); } if (!isset($errormsg) && isset($_POST["MM_insert"]) && $_POST["MM_insert"] == "form1") { { $cardexpiration = $_POST['cardexpmonth'].'/'.$_POST['cardexpyear']; $rentals = $_POST['RentalIDs']; $equery = "Insert into reservation_request (rentalid, firstname, middlename, lastname, address1, address2, country, state, city, postalcode, cellphone, dayphone, eveningphone, email, trip, triptype, tripdate, triptime, tripadult, tripchild, tripinfant, lodgingrequest, lodgingdate,lodgingdatecheckout, lodgingadult, lodgingchild, lodginginfant, nameoncard, cardtype, cardnumber, cardexpiration, verifactioncode, cardcomment, comments,createddatettime,type) values ('" .$colname_Recordset1 . "', '" . $_POST["firstname"] . "', '" . $_POST["middlename"] . "', '" . $_POST["lastname"] . "', '" .$_POST['address1'] . "', '" .$_POST['address2'] . "', '" .$_POST['country'] . "', '" .$_POST['state'] . "', '" .$_POST['city'] . "', '" .$_POST['postalcode'] . "', '" .$_POST['cellphone'] . "', '" .$_POST['dayphone'] . "', '" .$_POST['eveningphone'] . "', '" .$_POST['email'] . "', '" .$_POST['trip'] . "', '" .$_POST['triptype'] . "', '" .$_POST['tripdate'] . "', '" .$_POST['triptime'] . "', '" .$_POST['tripadult'] . "', '" .$_POST['tripchild'] . "', '" .$_POST['tripinfant'] . "', '" .$_POST['lodgingrequest'] . "', '" .$_POST['lodgingdate'] . "', '" .$_POST['lodgingdatecheckout'] . "', '" .$_POST['lodgingadult'] . "', '" .$_POST['lodgingchild'] . "', '" .$_POST['lodginginfant'] . "', '" .$_POST['nameoncard'] . "', '" .$_POST['cardtype'] . "', '" .$_POST['cardnumber'] . "', '" .$cardexpiration . "', '" .$_POST['verifactioncode'] . "', '" .$_POST['cardcomment'] . "', '" .$_POST['comments'] . "','".date('Y-m-d H:i:s')."', '" .$type. "')"; mysqli_query( $Vacation ,$equery) or die(mysqli_error()); /*while ($row_Recordset1 = mysqli_fetch_assoc($Recordset1)) { $equery = "Insert into emails (rentalid, memberid, source, sourceid, datesent) values ('" . $row_Recordset1["rentalid"] . "', '" . $row_Recordset1["memberid"] . "', '" . $row_Recordset1["source"] . "', '" . $row_Recordset1["sourceid"] . "', '" . date('Y-m-d') . "')"; mysqli_query( $Vacation ,$equery) or die(mysqli_error()); $name = $row_Recordset1['firstname'] . " " . $row_Recordset1['firstname'];*/ //$email = $row_Recordset1['email']; $email = 'brenda@carolinaoutfitters.com , dev.kafe.adom@gmail.com'; $eol = "\r\n"; $message = "A potential renter has viewed your property on the Top Choice Vacation Rentals Website and has sent you a Request for Information about your Vacation Rental:" . "$eol$eol"; $message .= "Vacation Rental #"; $message .= $colname_Recordset1. "$eol"; //$message .= $row_Recordset1['listingheadline'] . "$eol"; //$message .= $row_Recordset1['rentalcity'] . " " . $row_Recordset1['rentalstatecode'] . $row_Recordset1['countryname'] . "$eol"; if($type == 'rental') { $message .= "http://www.topchoicevacationrentals.com/details.php?rentalid=" . $colname_Recordset1 . "$eol$eol"; } else { $message .= "http://www.topchoicevacationrentals.com/attraction.php?attractionid=" . $colname_Recordset1 . "$eol$eol"; } $message .= "Submitted by: " . $_POST["firstname"] . " ".$_POST['middlename']. " " . $_POST["lastname"] . "$eol"; $message .= "Email: " . $_POST["email"] . "$eol"; $message .= "Day Phone: " . $_POST["dayphone"] . "$eol"; $message .= "Evening Phone: " . $_POST["eveningphone"] . "$eol"; //$message .= "Heard about us: " . $_POST["howdidyouhear"] . "$eol"; $message .= "Comments: " . $_POST["comments"] . "$eol"; $headers = "MIME-Version: 1.0$eol"; // $headers .= "Content-type: text/html; charset=iso-8859-1$eol"; $headers .= "From: " . $_POST["firstname"] . " " . $_POST["lastname"] . " <" . $_POST["email"] . ">$eol"; // if ($row_Recordset1['source'] == 'tcvr') $headers .= "Bcc:webmaster@topchoicevacationrentals.com\n"; if ($row_Recordset1['isforsale'] == 'Y') $Subject = "Top Choice Vacation Rental Inquiry"; else $Subject = "Top Choice Vacation Rentals Lodging Inquiry"; $emresult = mail($email, $Subject, $message, $headers); //echo "
" . $message . "
Vacation Rental: , #VACATION RENTAL INFORMATIONCONTACT THE PROPERTY MANAGER -if (isset($errormsg)){ echo "";
foreach($errormsg as $msg){
echo "$msg If you are trying to contact "Top Choice Vacation Rentals" please go HERE TRAVELERS: Find out availability or more information by filling out the form below.
Please fill in the form below, letting the property manager know what questions or comments you have, and we'll process your request as soon as we get it! Once the form is completed, simply hit "Submit"! We will respond to your inquiry by email. Thanks! |
Printer-Friendly Page | Bookmark This Vacation Rental Site | if (isset($_GET['rentalid'])) { ?> " STYLE="font-size: 8 pt">Email This Page to a Friend } else { ?> " STYLE="font-size: 8 pt">Email This Page to a Friend } ?>
Home |
Vacation Rental FAQ's |
About Top Choice Vacation Rentals |
Contact Us |
Vacation Rental Press Room
TCVR Members Log In |
List Your Rental |
Properties For Sale |
Vacation Rentals Specials |
Featured Rentals
Calendar of Events |
Renters Testimonials |
Join Our Frequent User E-Club |
E Vacation Planner
New Vacation Rental Listings |
Link with Us |
Our Friends
Copyright © 2005 by Top Choice Vacation Rentals All Rights Reserved |
Copyright © 2005 by Top Choice Vacation Rentals All Rights Reserved | Privacy & Legal Statement | Site Map