je viens de me rendre compte que le formulaire de mon client est ok avec Mozi Firefox mais que IE bloque l'envoi du formulaire. Le form comprend un capcha simple dy type 2+2=
Je ne vois plus rien
Pb de code php avec IE (balises ???)
Merci de me dire
Merci!
voici le code
<?php
// récupération des variables
$i=0;
foreach ($_POST as $key => $value){
if ($i == 0) {$allpost = '&'.$key.'='.$value;}
if ($i>0) {$allpost .= '&'.$key.'='.$value;}
$i++;
}
$name = $_POST['name'];
$tel = $_POST['tel'];
$adresse = $_POST['adresse'];
$ville = $_POST['ville'];
$mail = $_POST['mail'];
$codepostal = $_POST['codepostal'];
$capcha = $_POST['capcha'];
$doc = $_POST['doc'];
$appel = $_POST['appel'];
$desinsectisation = $_POST['desinsectisation'];
$desinfection = $_POST['desinfection'];
$demoustication = $_POST['demoustication'];
$jardin = $_POST['jardin'];
$denrees = $_POST['denrees'];
$deratisation1 = $_POST['deratisation'];
$depigeonnage = $_POST['depigeonnage'];
$chauvesouris = $_POST['chauvesouris'];
$preventif = $_POST['preventif'];
$curatif = $_POST['curatif'];
$charpentes = $_POST['charpentes'];
$art = $_POST['art'];
$franchise = $_POST['franchise'];
$message = $_POST['message'];
// On peuple
if (!empty($desinsectisation)) {$un = '<li>désinsectisation</li>'."\n";}
if (!empty($desinfection)) {$deux = '<li>désinfection</li>'."\n";}
if (!empty($demoustication)) {$trois = '<li>démoustication</li>'."\n";}
if (!empty($jardin)) {$quatre = '<li>traitement des jardins</li>'."\n";}
if (!empty($denrees)) {$onze = '<li>fumigation des denrées stockées</li>'."\n";}
if (!empty($deratisation)) {$cinq = '<li>deratisation</li>'."\n";}
if (!empty($depigeonnage)) {$six = '<li>depigeonnage</li>'."\n";}
if (!empty($chauvesouris)) {$sept = '<li>chauve-souris</li>'."\n";}
if (!empty($preventif)) {$huit = '<li>traitement préventif anti-termites</li>'."\n";}
if (!empty($curatif)) {$neuf = '<li>traitement curatif anti-termites</li>'."\n";}
if (!empty($charpentes)) {$douze = '<li>traitement des charpentes</li>'."\n";}
if (!empty($art)) {$treize = '<li>fumigation du mobilier et des objets d\'art</li>'."\n";}
if (!empty($franchise)) {$dix = '<li>demande d\'informations sur la franchise</li>'."\n";}
if (!empty($doc)) {$doc = 'oui';} else {$doc = 'non';}
if (!empty($appel)) {$appel = 'oui';} else {$appel = 'non';}
$html = '<h3>Données client :</h3><span style="text-transform:uppercase; font-size:large;">'.$name.'</span></strong><br />';
$html .= 'Téléphone: '.$tel.'<br />Adresse: '.$adresse.'<br />Ville: '.$ville.'<br/>Mail : <a href="mailto:'.$mail.'">'.$mail.'</a><br />Code Postal: '.$codepostal.'<br />';
$html .= 'Demande de documentation: '.$doc.'<br />';
$html .= 'Appeler le client pour un devis gratuit: '.$appel.'<br />';
$html .= '<h3>Rendez-vous souhaité:</h3><strong>Le client souhaite un rendez-vous pour:</strong><br />';
$html .= '<ul>'.$un.$deux.$trois.$quatre.$onze.$cinq.$six.$sept.$huit.$neuf.$douze.$treize.$dix.'</ul><br />';
$html .= '<h3>Commentaires : </h3>'.stripslashes(nl2br($message));
if ($capcha == 4) {
if (mb_eregi("^[0-9a-z]([-_.]?[0-9a-z])*@[0-9a-z]([-.]?[0-9a-z])*\.[a-z]{2,3}$", $mail) ) {
//header html
$headers = 'MIME-Version: 1.0' . "\n";
$headers .= 'Content-type: text/html; charset=utf-8' . "\n";
$headers .= 'From: "Stopinsectes.com"<[email protected]>'."\n";
$headers .= 'Bcc: [email protected],[email protected]@c-carre.com'."\n";
$reply = $headers.'Reply-to: [email protected]'."\n";
if( mail('[email protected]','Formulaire Stop Insectes', $html, $reply) ){
echo '<p><span class="blockquote">les informations on bien été envoyées</span></p>';
}
else{
echo '<p><span class="blockquote">La fonction mail() est désactivée sur ce serveur.</p>';
}
} else {
echo '<p><span class="blockquote">Veuillez vérifier votre adresse mail.</p>';
}
} else {
echo '<p><span class="blockquote">Veuillez vérifier le code de sécurité</p>';
}
?>