| Server IP : 10.200.247.200 / Your IP : 216.73.217.19 Web Server : Apache System : Linux synergy-usa-sites 6.8.0-138-generic #138-Ubuntu SMP PREEMPT_DYNAMIC Fri Jul 31 22:41:49 UTC 2026 x86_64 User : jeremy ( 1001) PHP Version : 8.4.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/hans_sites/bluffstreetexecutivesuites.com/ |
Upload File : |
<?php
$body_id = 'contact';
require_once('header.php');
require_once('globals.php');
require_once "formvalidator.php";
if(isset($_POST['Submit']))
{
//Recaptcha
if(!function_exists('PostFields')) {
function PostFields($url,$fields)
{
$fields = http_build_query($fields);
$ch = curl_init();
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt($ch, CURLOPT_REFERER, $_SERVER["HTTP_HOST"] . $_SERVER['REQUEST_URI']);
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $fields);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($ch, CURLOPT_USERAGENT, "LCAPI cUrl Agent");
curl_setopt($ch, CURLOPT_VERBOSE, true);
ob_start();
$data = curl_exec ($ch);
ob_end_clean();
curl_close ($ch);
return $data;
}
}
$postfields = array();
$postfields['secret'] = '6Ld1puMZAAAAAFokcJIN3GJ47Kgyfbkm5UakfObV';
$postfields['response'] = $_POST['g-recaptcha-response'];
$postfields['remoteip'] = $_SERVER['REMOTE_ADDR'];
$recaptcha_response = PostFields('https://www.google.com/recaptcha/api/siteverify',$postfields);
$json_response = json_decode($recaptcha_response);
$recaptcha_passed = false;
if($json_response->success) {
if($_SERVER['REMOTE_ADDR']!='37.139.53.230') {
$recaptcha_passed = true;
$validator = new FormValidator();
$validator->addValidation("nam","req","Full Name");
$validator->addValidation("eml","email","Please enter a valid email");
$validator->addValidation("eml","req","Valid Email Address");
$validator->addValidation("ph3","req","Current Valid Phone");
$validator->addValidation("sub","req","Choose Subject");
$validator->addValidation("mes","req","Message");
if($validator->ValidateForm())
{
//$to = "etoddt@gmail.com";
$to = "frontoffice@bluffstreetexecutivesuites.com";
$headers = 'From: Bluff Street Executive Suites <frontoffice@bluffstreetexecutivesuites.com>' . "\r\n";
$co = "Bluff Street Executive Suites";
$co2 = "Bluff Street Executive Suites <frontoffice@bluffstreetexecutivesuites.com>";
$nam = $_POST['nam'];
$eml = $_POST['eml'];
$ph1 = $_POST['ph1'];
$ph2 = $_POST['ph2'];
$ph3 = $_POST['ph3'];
$sub = $_POST['sub'];
$oth = $_POST['subject'];
$mes = $_POST['mes'];
$dat = date("F j, Y, g:i A");
$body ="
$sub - received $dat.\n
From: $nam
E-Mail: $eml
Phone: ($ph1) $ph2-$ph3
Subject: $sub $oth
Message: \r\n$mes\n
";
$body2 ="
Thank you for your interest in Bluff Street Executive Suites (USFE) \n
We received your email on $dat and are processing your inquiry.\n
A representative will respond within 24-48 hours.\n\n
Below is a copy of the information we receieved.\n
From: $nam
E-Mail: $eml
Phone: ($ph1) $ph2-$ph3
Subject: $sub $oth
Message: \r\n$mes\n\n
NOTE: DO NOT RESPOND TO THIS EMAIL.\n
Please send all email correspondence to frontoffice@bluffstreetexecutivesuites.com\n
";
require_once($_SERVER['DOCUMENT_ROOT'].'/php/mailgun.php');
mailgun_send_message($to,'frontoffice@bluffstreetexecutivesuites.com','Bluff Street Executive Suites',nl2br($body),1,'BluffStreet Contact','','','',0,array(),'',0);
mailgun_send_message($eml,'frontoffice@bluffstreetexecutivesuites.com','Bluff Street Executive Suites',nl2br($body2),1,'BluffStreet Contact','','','',0,array(),'',0);
/*if(mail($to.',jeremy@synergytpsreports.com', $co, $body, "From: $co2\r\n", '-fnoreply@surfcrm.com')){
mail($eml, $co, $body2, $headers);
$output = '<p class="success" style="width:635px"><b>THANK YOU!</b> Please allow 24-48 hours for a representative to contact you regarding your inquiry.</p>';
$reset = 'reset';
}*/
$output = '<p class="success" style="width:635px"><b>THANK YOU!</b> Please allow 24-48 hours for a representative to contact you regarding your inquiry.</p>';
$reset = 'reset';
} else {
$output .= "<p class='error' style='width:635px'>";
$output .= "<b>SORRY -</b> We need you to input";
$error_hash = $validator->GetErrors();
foreach($error_hash as $inpname => $inp_err)
{
$output .= ", <u>$inp_err</u>";
}
$output .= "</p>";
}
}
} else {
$output .= "<p class='error' style='width:635px'>";
$output .= "The recaptcha failed";
$output .= "</p>";
}
}
require_once("header.php");?>
<script src="https://www.google.com/recaptcha/api.js" async defer></script>
<? if(isset($_POST['category'])) { ?>
<script type="text/javascript">
$('document').ready(function() {
$('#<?= $_POST['category'];?>').click();
});
</script>
<? }?>
<style type="text/css">
.padding{padding:40px}
.hours {
padding: 0;
display:-webkit-flex;
display:-ms-flex;
display:flex;
-webkit-justify-content: space-evenly;
-ms-justify-content: space-evenly;
justify-content: space-evenly;
}
@media screen and (max-width:768px) {
.hours {
padding: 40px 0;
}
table.contact > tbody > tr > td {
width:100%;
float:left;
}
}
@media screen and (max-width:600px) {
.hours {
padding: 20px;
-webkit-flex-direction: column;
-ms-flex-direction: column;
flex-direction: column;
}
#dform input {margin:0}
.padding{padding:20px}
}
</style>
<script language="javascript" type="text/javascript" src="script.js"></script>
<article>
<div class="row" style="padding-top:70px">
<div class="column" style="width:100%">
<h1>Contact Us</h1>
<p style="margin:0 0 0 25px">For any questions, please call us Free Number at <strong><?php echo $_SITE_PHONE ?></strong> during the hours below.</p>
<div class="hours" >
<div>
<h2>Hours:</h2>
<table cellspacing="0" cellpadding="0">
<tr>
<td nowrap="nowrap">Monday - Friday</td>
<td nowrap="nowrap" style="padding-left:15px;">8AM-5PM</td>
</tr>
</table>
</div>
<div>
<h2>Mailing Address:</h2>
<p><?=$_SITE_ADDR;?></p>
</div>
</div>
</div>
</div>
</article>
<article style="background-color:#eee">
<div class="row">
<div class="column" style="margin: 0 auto;">
<div class="padding">
<h2>Contact Form:</h2>
<form name="dform" id="dform" method="post" action="" accept-charset="UTF-8">
<?php print $output;?>
<input type="hidden" id="check" value="<?php print $reset?>" onclick="javscript:return clearForms();" />
<table cellpadding="0" cellspacing="0" border="0" class="contact">
<tr>
<td>
<label>Full Name<br />
<input name="nam" type="text" style="width:285px; margin-right:5px"
onblur="this.style.color=suces; javascript:return valName('dform','nam');" onfocus="this.style.color=focci"
value="<?php if (isset($_POST['nam'])){echo htmlspecialchars($_POST['nam'], ENT_QUOTES);}?>" /></label></td>
<td class="nowrap">
<label>Phone<br />
(
<input name="ph1" maxlength="3" type="text" style="width:50px"
onKeyDown="TabNext(this,'down',3)"
onblur="valNum(this);this.style.color=suces;" onfocus="this.style.color=focci"
onKeyUp="TabNext(this,'up',3,this.form.ph2)"
value="<?php if (isset($_POST['ph1'])){echo htmlspecialchars($_POST['ph1'], ENT_QUOTES);}?>" />
)
<input name="ph2" maxlength="3" type="text" style="width:50px"
onKeyDown="TabNext(this,'down',3)"
onblur="valNum(this);this.style.color=suces;" onfocus="this.style.color=focci"
onKeyUp="TabNext(this,'up',3,this.form.ph3)"
value="<?php if (isset($_POST['ph2'])){echo htmlspecialchars($_POST['ph2'], ENT_QUOTES);}?>" />
-
<input name="ph3" maxlength="4" type="text" style="width:60px"
onblur="valNum(this);this.style.color=suces;" onfocus="this.style.color=focci"
value="<?php if (isset($_POST['ph3'])){echo htmlspecialchars($_POST['ph3'], ENT_QUOTES);}?>" />
</label>
</td>
</tr>
<tr>
<td>
<label>Subject<br />
<input type="text" id="sub" name="sub" style="width:280px" value="<?= (isset($_POST['sub'])) ? $_POST['sub'] : '';?>" /></label>
</td>
<td>
<label>Email Address<br />
<input name="eml" type="text" style="width:280px;"
onblur="javascript:return valEmail('dform','eml')"
value="<?php if (isset($_POST['eml'])){echo htmlspecialchars($_POST['eml'], ENT_QUOTES);}?>" /></label></td>
</tr>
<tr>
<td class="required">Message</td>
<td></td>
</tr>
<tr>
<td colspan="2"><textarea name="mes" style="width:100%;box-sizing:border-box" rows="6"
onblur="this.style.color=suces" onfocus="this.style.color=focci"><?php if (isset($_POST['mes'])){echo htmlspecialchars($_POST['mes'], ENT_QUOTES);}?></textarea></td>
</tr>
<tr>
<td colspan="4" align="center">
<script type="text/javascript" language="javascript">
<!--
onload = function() {
if(document.getElementById('check').value != '') {
setTimeout('clearForms()', 200);
}
if(document.dform.subject.value != '') {
document.getElementById('other_subject').style.display = 'block';
}
if(document.getElementById('new').checked == true) {
document.getElementById('contact').style.display = 'block';
} else if(document.getElementById('existing').checked == true) {
document.getElementById('signin').style.display = 'block';
}
}
-->
</script>
<center style="padding:10px 0px 20px 0px;">
<div style="display:inline-block;">
<div class="g-recaptcha" data-sitekey="6Ld1puMZAAAAAL1ZV0af75SEkqkA5g9DvJg9ZSyD"></div>
</div>
</center>
<center>
<input type="submit" name="Submit" class="submit" value="SUBMIT" />
</center>
</td>
</tr>
</table>
</div>
</form>
</div>
</div>
</div>
</article>
<?php require_once('footer.php')?>