| Current Path : /home/happyrenas/old/devis-huissier.fr/old/ |
Linux webd005.cluster105.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 |
| Current File : /home/happyrenas/old/devis-huissier.fr/old/validation.php |
<?php
require('config.php');
$pageTitle = $TITLE_accueil;
$pageDescription = $DESCR_accueil;
$page="accueil";
require('includes/header.php');
?>
<div id="visuel-header">
<div class="container">
<div class="row">
<h1 class="h1 col-xs-12">
Obtenez un devis d'huissier<br/>
<span>en EXPRESS partout en France</span>
</h1>
</div>
</div>
</div>
</header>
<?php
$bloc = $db->escape($_POST['bloc']);
if ($bloc==1) {$objet = "DEVIS HUISSIER : Nouvelle demande IMPAYE";$type_impaye_mail="IMPAYE";}
if ($bloc==2) {$objet = "DEVIS HUISSIER : Nouvelle demande CONSTAT";$type_impaye_mail="CONSTAT";}
if ($bloc==3) {$objet = "DEVIS HUISSIER : Nouvelle demande AUTRE BESOIN";$type_impaye_mail="AUTRE BESOIN";}
$montant_impaye = $db->escape($_POST['montant_impaye']);
$montant_impaye = str_replace(".",",",$montant_impaye);
$type_impaye = $db->escape($_POST['type_impaye']);
$constat_type = $db->escape($_POST['constat_type']);
$plage_jour = $db->escape($_POST['plage_jour']);
$plage_heure = $db->escape($_POST['plage_heure']);
$constat_adresse = $db->escape($_POST['constat_adresse']);
$constat_cp = $db->escape($_POST['constat_cp']);
$constat_ville = $db->escape($_POST['constat_ville']);
$besoin = $db->escape($_POST['besoin']); $besoin_type = $db->escape($_POST['besoin_type']);
$nom = $db->escape($_POST['nom']);
$prenom = $db->escape($_POST['prenom']);
$adresse = $db->escape($_POST['adresse']);
$cp = $db->escape($_POST['cp']);
$ville = $db->escape($_POST['ville']);
$departement = $db->escape($_POST['departement']);
$lieu_intervention = $db->escape($_POST['lieu_intervention']);
$telephone = $db->escape($_POST['telephone']);
$email = $db->escape($_POST['email']);
$commentaire = $db->escape($_POST['commentaire']);
$date_creation = date("Y-m-d H:i");
$date_creation = date("Y-m-d H:i", strtotime($date_creation));
$statut = 1;
if (strstr($prenom, 'https')) {$prenom="off";}
if ($prenom=="off") {exit;}
if ($prenom=="GrantAgoth") {exit;}
if ($prenom=="JAMES COOK") {exit;}
if ($ville=="GrantAgoth") {exit;}
if ($ville=="Jameswer") {exit;}
// INSERTION DEVIS
if ($email) {
$requete="INSERT INTO devis(
bloc,
nom,
prenom,
adresse,
cp,
ville,
departement,
lieu_intervention,
telephone,
email,
commentaire,
montant_impaye,
type_impaye,
constat_type,
plage_jour,
plage_heure,
constat_adresse,
constat_cp,
constat_ville,
besoin, besoin_type,
statut,
date_creation
)
VALUES(
'$bloc',
'$nom',
'$prenom',
'$adresse',
'$cp',
'$ville',
'$departement',
'$lieu_intervention',
'$telephone',
'$email',
'$commentaire',
'$montant_impaye',
'$type_impaye',
'$constat_type',
'$plage_jour',
'$plage_heure',
'$constat_adresse',
'$constat_cp',
'$constat_ville',
'$besoin', '$besoin_type', '$statut',
'$date_creation')";
$db->query($requete);
$message="insert_client_ok";
//echo $requete;
/// MAIL TO THE ADMIN
require_once('includes/class.phpmailer.php');
require_once('includes/class.smtp.php');
include('includes/mail_formulaire.php');
//foreach($_POST as $key=>$val)
//{
//if ($key!='bloc') {$information = $information. $key. " : ".$val."<br>";}
//}
if ($montant_impaye) {$information.="Montant : ".$montant_impaye."<br>";}
if ($type_impaye_mail) {$information.="Type : ".$type_impaye_mail."<br>";}
if ($constat_type) {$information.="Constat type : ".$constat_type."<br>";}
if ($plage_jour) {$information.="Plage jour : ".$tableau_plage_jour[$plage_jour]."<br>";}
if ($plage_heure) {$information.="Plage heure : ".$tableau_plage_heure[$plage_heure]."<br>";}
if ($constat_adresse) {$information.="Adresse constat : ".$constat_adresse." ".$constat_cp. " " .$constat_ville."<br>";}
if ($besoin) {$information.="Besoin : ".$_POST['besoin']."<br>";}
if ($nom) {$information.="Nom : ".$nom."<br>";}
if ($prenom) {$information.="Prenom : ".$prenom."<br>";}
if ($adresse) {$information.="Adresse : ".$adresse." ".$cp. " " .$ville."<br>";}
if ($departement) {$information.="Departement : ".$departement."<br>";}
if ($lieu_intervention) {$information.="Lieu d intervention : ".$lieu_intervention."<br>";}
if ($telephone) {$information.="Telephone : ".$telephone."<br>";}
if ($email) {$information.="Email : ".$email."<br>";}
if ($commentaire) {$information.="Commentaire : ".$_POST['commentaire']."<br><br>";}
$from = "info@devis-huissier.fr";
$from_name = "DEVIS-HUISSIER.FR";
$destinataire = "info@devis-huissier.fr";
$reply = "info@devis-huissier.fr";
$mail = new PHPmailer();
$mail->SMTPDebug = 0;
$mail->CharSet = "UTF-8";
$mail->IsHTML(true);
$mail->setFrom($from,$from_name);
$mail->AddAddress($destinataire);
$mail->AddBCC("philippe-jean@outlook.fr");
$mail->AddEmbeddedImage("/home/happyrenas/devis-huissier.fr/images/logo1.png","logo");
$mail->AddReplyTo($reply);
$mail->Subject="[JRD] ".$objet;
$mail->Body=$information;
if(!$mail->Send())
{
echo $mail->ErrorInfo;
}
else
{
$msg="..";
}
/// MAIL TO THE CLIENT
$information="";
$information="Bonjour, <br><br>";
$information.="Vous venez de poster une demande de devis sur devis-hussier.fr<br><br><i>";
if ($montant_impaye) {$information.="Montant : ".$montant_impaye."<br><br>";}
if ($type_impaye_mail) {$information.="Type : ".$type_impaye_mail."<br><br>";}
if ($constat_type) {$information.="Constat type : ".$constat_type."<br><br>";}
if ($plage_jour) {$information.="Plage jour : ".$tableau_plage_jour[$plage_jour]."<br><br>";}
if ($plage_heure) {$information.="Plage heure : ".$tableau_plage_heure[$plage_heure]."<br><br>";}
if ($constat_adresse) {$information.="Adresse constat : ".$constat_adresse." ".$constat_cp. " " .$constat_ville."<br><br>";}
if ($besoin) {$information.="Besoin : ".$_POST['besoin']."<br><br>";}
if ($nom) {$information.="Votre nom : ".$nom."<br><br>";}
if ($prenom) {$information.="Votre prenom : ".$prenom."<br><br>";}
if ($adresse) {$information.="Votre adresse : ".$adresse." ".$cp. " " .$ville."<br><br>";}
if ($departement) {$information.="Departement : ".$departement."<br><br>";}
if ($lieu_intervention) {$information.="Lieu d intervention : ".$lieu_intervention."<br><br>";}
if ($telephone) {$information.="Telephone : ".$telephone."<br><br>";}
if ($email) {$information.="Email : ".$email."<br><br>";}
if ($commentaire) {$information.="Commentaire : ".$_POST['commentaire']."<br><br>";}
$information.="</i>Vous allez recevoir plusieurs devis d'huissiers de votre localité.<br><br>";
$information.="Cordialement,<br><br>";
$information.="L'équipe Devis Huissier<br><br>";
$information.="assistance@devis-huissier.fr";
include('includes/mail_formulaire_client.php');
$objet = "Devis-Huissier : votre demande de devis";
$from = "info@devis-huissier.fr";
$from_name = "DEVIS-HUISSIER.FR";
$reply = "info@devis-huissier.fr";
$mail = new PHPmailer();
$mail->SMTPDebug = 0;
$mail->CharSet = "UTF-8";
$mail->IsHTML(true);
$mail->setFrom($from,$from_name);
$mail->AddAddress($email);
$mail->AddBCC("philippe-jean@outlook.fr");
$mail->AddEmbeddedImage("/home/happyrenas/devis-huissier.fr/images/logo1.png","logo");
$mail->AddReplyTo($reply);
$mail->Subject=$objet;
$mail->Body=$message;
if(!$mail->Send())
{
echo $mail->ErrorInfo;
}
else
{
$msg="..";
}
}
?>
<div id="main">
<div class="container">
<div class="row">
<div class="form-contact col-xs-12 col-md-10 col-md-offset-1">
<form class="form-horizontal">
<div class="row center">
<h2 class="h2 bleu">Merci !</h2>
<p>
Votre demande a bien été validée.<?echo $msg;?>
<br/><br/>
</p>
</div>
</form>
</div>
</div>
</div>
</div>
<aside id="accelerateurs">
<div class="container">
<div class="row center">
<a href="<?php echo $NAV_tarifs;?>" title="<?php echo $NAV_TITLE_tarifs;?>" class="col-xs-12 col-sm-4">
<img src="components/images/tarif-des-actes-huissiers-en-france.png" alt="Tarif des actes d'huissiers">
<br/><br/>
<strong>TARIF DES ACTES</strong>
<br/><br/>
<b>
Guide des prix des constats, des recouvrements d’impayés, et des tarifs des actes d’huissier
</b>
</a>
<a href="<?php echo $NAV_accueil;?>" title="<?php echo $NAV_TITLE_accueil;?>" class="col-xs-12 col-sm-4">
<img src="components/images/votre-constat-huissier-rapidement.png" alt="Votre constat d'huissier rapidement">
<br/><br/>
<strong>VOTRE DEVIS</strong>
<br/><br/>
<b>
Faites votre demande en ligne et recevez gratuitement des devis d’huissiers proche de chez vous
</b>
</a>
<a href="<?php echo $NAV_annuaire;?>" title="<?php echo $NAV_TITLE_annuaire;?>" class="col-xs-12 col-sm-4">
<img src="components/images/notre-annuaire-des-huissiers-en-france.png" alt="Annuaire des huissiers en France">
<br/><br/>
<strong>NOTRE ANNUAIRE</strong>
<br/><br/>
<b>
Trouver les coordonnées et localiser votre huissier parmi les 3224 huissiers répertoriés en France
</b>
</a>
</div>
</div>
</aside>
<?php
require('includes/footer.php');
?>