%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /home/alliance/domains/congress-intercultural.eu/public_html/
Upload File :
Create Path :
Current File : /home/alliance/domains/congress-intercultural.eu/public_html/p-contact.php

<?php
include_once("inc/config.php");
include_once("inc/functions.php");
include_once("inc/init.php");

//affichage du html
include("theme/html.php");
//affichage des metas
include("theme/meta.php");
echo "\n<title>Contact - ".$info_titresite."</title>\n";
?>
<script src='https://www.google.com/recaptcha/api.js?hl=<?php echo $lang->getlang(); ?>'></script>
<?php
//affichage du header
include("theme/header.php");
//colonne de droite
include("theme/droite.php");

?>

<section class="text">
<div class="block_titre2">
	<h1 ><?=$trad->t("Contact-us","front",$lang->id())?></h1>
</div>
<div id="filariane">
	<a style="color:#<?=$cat_theme['couleur']?>" href="<?=$url_site.$lang->getlang()?>/" class="link_home"><i class="fa fa-home" aria-hidden="true"></i></a> <i class="fa fa-caret-right" aria-hidden="true"></i> 
	<div style="color:#<?=$cat_theme['couleur']?>" class="link"><?=$trad->t("Contact-us","front",$lang->id())?></div>
</div>

<?php

if(isset($_POST['post']) && $_POST['post'] == 1)
{
	$db = new BaseOps;
	$erreur = true;
	if (!$_POST['nom'])
	{
		$erreurtxt = ": ".lang("nom").lang("pasrempli");
		$erreur = false;
	}
	if (!$_POST['prenom'])
	{
		$erreurtxt = ": ".lang("prenom").lang("pasrempli");
		$erreur = false;
	}
	if (!$_POST['message'])
	{
		$erreurtxt = ": ".lang("texte").lang("pasrempli");
		$erreur = false;
	}
	if(!$_POST['email'])
	{
		$erreurtxt = ": ".lang("email").lang("pasrempli");
		$erreur = false;
	}
	else {
		$email_check = verifie_email($_POST['email']);
		if ($email_check != "ok")
		{
			$erreurtxt = ": ".lang("email").lang("pasbienrempli");
			$erreur = false;
		}
	}
	/*$captcha;
	if(isset($_POST['g-recaptcha-response'])){
		$captcha = $_POST['g-recaptcha-response'];
	}
	if(!$captcha){
		$erreurtxt = ": Captcha".lang("pasrempli");
		$erreur = false;
	}
	$response=file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=6Ldb3AwTAAAAAGz0cD6EYqeuhsIMTQphxdZBd1v6&response=".$captcha."&remoteip=".$_SERVER['REMOTE_ADDR']);
	if($response.success==false) {
		$erreurtxt = ": Captcha failed, you must be humain to send a message.";
		$erreur = false;
	}*/
	if ($erreur) // si pas d'erreurs
	{
		// envoi du mail de validation
		$subject=utf8_decode("Message sur le site Alliance");
		$headers= "From: ".$_POST['email']."\n";
		$headers.='Content-type: text/html; charset=utf-8';
		$message='';
		$message.=stripslashes("<p><strong>Message sur le site Alliance,</strong></p><br />
		<p>De : ".$_POST['prenom']." ".$_POST['nom']." ".$_POST['societe']."</p>
		<p>N° de téléphone : ".$_POST['telephone']."</p>
		<p>Message :</p>
		<p>".nl2br($_POST['message'])."</p>");

		mail($email_contact, $subject, "
		<html>
		<head>
		 <title>Contact letter</title>
		</head>
		<body>
		<br>
		  ".$message."
		</body>
		</html>" , $headers);
		echo "<div class=\"infobloc\">Votre message à été envoyé</div>";
	}
	else {
		echo "<div class=\"erreurbloc\">".lang("error")." ".$erreurtxt."</div>";
	}
}

?>
	<form action="<?php echo $lang->getlang(); ?>/contact/" method="post" class="form form_contact">
	<table>
		<tr>
			<td class="label"><?php echo lang("email"); ?> <span class="etoile">*</span></td>
			<td class="field"><input type="text" name="email" value="<?=((isset($_POST['email']))?$_POST['email']:""); ?>" /></td>
		</tr>
		<tr>
			<td class="label top"><?php echo lang("nom"); ?> <span class="etoile">*</span></td>
			<td class="field"><input type="text" name="nom" value="<?=((isset($_POST['nom']))?$_POST['nom']:""); ?>" /></td>
		</tr>
		<tr>
			<td class="label top"><?php echo lang("prenom"); ?> <span class="etoile">*</span></td>
			<td class="field"><input type="text" name="prenom" value="<?=((isset($_POST['prenom']))?$_POST['prenom']:""); ?>" /></td>
		</tr>
		<tr>
			<td class="label top"><?php echo lang("societe"); ?></td>
			<td class="field"><input type="text" name="societe" value="<?=((isset($_POST['societe']))?$_POST['societe']:""); ?>" /></td>
		</tr>
		<tr>
			<td class="label top"><?php echo lang("telephone"); ?></td>
			<td class="field"><input type="text" name="telephone" value="<?=((isset($_POST['telephone']))?$_POST['telephone']:""); ?>" /></td>
		</tr>
		<tr>
			<td class="label top"><?php echo lang("texte"); ?> <span class="etoile">*</span></td>
			<td class="field top"><textarea name="message"><?=((isset($_POST['message']))?$_POST['message']:""); ?></textarea></td>
		</tr>
	</table>
	<div class="form_bouton">
		<!--<div class="g-recaptcha" data-sitekey="6Ldb3AwTAAAAANuEO-T1aj9PuC1Hc3xO2nt-gfLm"></div>-->
		<input type="hidden" name="post" value="1" />
		<input type="submit" class="bouton" id="maj_bouton" value="<?php echo lang("sendmess"); ?>" />
	</div>
</form>
</section>

<?

//affichage du footer
include("theme/footer.php");

?>

Zerion Mini Shell 1.0