Enquiry Form

You must enter a first name!

‘;
$error = true;
}
if($_POST[‘surname’] == ”) {
echo ‘

You must enter a surname!

‘;
$error = true;
}
if($_POST[‘deeds’] == ”) {
echo ‘

You must state if you are the only name on the deeds!

‘;
$error = true;
}

if($_POST[‘tel’] == ”) {
echo ‘

You must enter a telephone number!

‘;
$error = true;
}

if($_POST[‘address’] == ”) {
echo ‘

You must enter an address!

‘;
$error = true;
}
if($_POST[‘postcode’] == ”) {
echo ‘

You must enter a postcode!

‘;
$error = true;
}
if($_POST[‘property_type’] == ”) {
echo ‘

You must enter a property type!

‘;
$error = true;
}
if($_POST[‘beds’] == ”) {
echo ‘

You must enter the number of bedrooms!

‘;
$error = true;
}
if(!is_numeric($_POST[‘beds’])) {
echo ‘

Number of bedrooms must be a number!

‘;
$error = true;
}
if($_POST[‘estimate’] == ”) {
echo ‘

You must enter an estimated value for the property!

‘;
$error = true;
}
if(!is_numeric($_POST[‘estimate’])) {
echo ‘

Estimate of property value must be a number!

‘;
$error = true;
}
if($_POST[‘out_morg’] == ”) {
echo ‘

You must state if there is an outstanding mortgage!

‘;
$error = true;
}
if($_POST[‘charges’] == ”) {
echo ‘

You must state if you have a second mortgage or other charges!

‘;
$error = true;
}
if($_POST[‘comp_dead’] == ”) {
echo ‘

You must state if you have a deadline for completion!

‘;
$error = true;
}

if ($error != true) {

$to = “neil@discusgroup.co.uk, andrew@great-properties.co.uk”;
$subject = “New Great Properties Enquiry”;
$message = “Name:”.$_POST[‘firstname’].” “.$_POST[‘surname’].”\r\n”.”\r\n”.”Address: “.$_POST[‘address’].”\r\n”.”\r\n”.”Postcode: “.$_POST[‘postcode’].”\r\n”.”\r\n”.”Estimated Value: “.$_POST[‘estimate’];
$header = “From:”.$_POST[’email’];
mail ($to,$subject,$message,$header);

$query = “INSERT INTO gpcontact (firstname, surname, deeds, tel, email, address, postcode, property_type, other_type, beds, estimate, out_morg, charges, comp_dead, comp_date, reason, referral) VALUES (‘$_POST[firstname]’, ‘$_POST[surname]’,’$_POST[deeds]’, ‘$_POST[tel]’, ‘$_POST[email]’, ‘$_POST[address]’, ‘$_POST[postcode]’, ‘$_POST[property_type]’, ‘$_POST[other_type]’, $_POST[beds], $_POST[estimate], ‘$_POST[out_morg]’, ‘$_POST[charges]’, ‘$_POST[comp_dead]’, ‘$_POST[comp_date]’, ‘$_POST[reason]’, ‘$_POST[referral]’)”;
$result = mysqli_query($dbc,$query);

if($result) {
echo ‘Your enquiry has been successfully saved. You will hear from one of our team soon.’;

} else {
echo ‘

An error occurred!

‘;
echo mysqli_error($dbc);
echo ‘

‘.$query.’

‘;
}

}
}

?>

For FAST, FREE, CONFIDENTIAL IMPARTIAL Expert Advice please fill in the below form.

You will receive a Guaranteed Offer within 24 hours of us receiving all the information we need from you.


* required fields









One of our team will contact you shortly do discuss your requirements in more detail.

All the information we receive is handled in the strictest of confidence. We will not share any of the information with any outside party.