Les avertissements suivants se sont produits :
Warning [2] Undefined array key 0 - Line: 1640 - File: showthread.php PHP 8.2.18 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/showthread.php 1640 errorHandler->error_callback
/showthread.php 915 buildtree




Note de ce sujet :
  • Moyenne : 0 (0 vote(s))
  • 1
  • 2
  • 3
  • 4
  • 5
non reception duchoix d'un formulaire //RESOLU
#1
Citation :#~~~~~ DEBUT BLOC A NE PAS SUPPRIMER ~~~~~
#~ Version du CMS: !1.6.x
#~ Url du site : www.lapins-bleus.com
#~ Hébergeur / Soft :
#~ Informations Système :
#~~~~~ FIN BLOC A NE PAS SUPPRIMER ~~~~~


Bonjour,

j'ai crée un formaulaire à partir d'un existant sur le site (sans formbuilder, car l'entreprise qui a monté le site ne l'a pas utilisé), et je n'arrive pas à recevoir le choix coché dans le formulaire dans le mail de réception... (tout est vide alors que je choisis une proposition)
Ci-dessous le code, il doit manquer qqch dans ma méthode d'envoi ? je ne vois vraiment pas où est le problème...
Merci


$date_aujourdhui=date("Y-m-d");
$annee=date(y);
$annee2=$annee+1;

print"<script language=\"JavaScript\">
<!--
function valider() {
var form_err = \" \"


if ( document.information.email.value.length < 1) {
form_err += \"Email : merci de remplir ce champ - \";
}

var verim = 0;
for (i=1; i<document.information.email.value.length -4; i++) {
if ( document.information.email.value.charAt(i) == \"@\") {
verim = 1;
}
}

if ( verim == 0) {
form_err += \"Email invalide - \";
}

if ( form_err != \" \") {
alert(form_err);
return false;
}

if(document.getElementById('periode').style.visibility=='hidden') {
document.getElementById('mois').selectedIndex= 0;
document.getElementById('annee').selectedIndex= 0;
} else {
document.getElementById('session').selectedIndex= 0;
}

return true;
}


-->
</script>
";



print "
<div id='chemin-fer'><span style='color:#6c93c2; font-weight:bold;'>Vous êtes ici : </span> lapins bleus formations > <b>Quels workshops pour la rentrée ?</b></div>
<div style='width:954px; height:174px; margin-bottom:10px;'><img src='img/entete-actualite.gif' alt='' /></div>";

print "
<div id='centre-haut'></div>
<div id='middle'>
<div id='middle-bis'>
<div id='mainContent'>
<div id='content_gauche'>";

if ($_POST["envoi"] == "ok") {

$headers ='From: "Web"<NoReply@lapins-bleus.com>'."\n";
$headers .='Reply-To: NoReply@lapins-bleus.com'."\n";
$headers .='Content-Type: text/html; charset="utf-8"'."\n";
$headers .='Content-Transfer-Encoding: 8bit';

$message = '<html><head><title>formulaire fc - new</title></head><body>';
$message .= 'Lundi 21 novembre : '. $_POST["lundi"] .'<br />';
$message .= 'Mardi 22 novembre : '. $_POST["mardi"] .'<br />';
$message .= 'Mercredi 23 novembre : '. $_POST["mercredi"] .'<br />';
$message .= 'Jeudi 24 novembre : '. $_POST["jeudi"] .'<br />';
$message .= 'Vendredi 25 novembre: '. $_POST["vendredi"] .'<br />';
$message .= 'E-mail: '. $_POST["email"] .'<br />';
$message .= '</body></html>';

if(mail('fe@lapins-bleus.com', 'Demande d\'information en ligne', $message, $headers)) {
echo 'Un e-mail nous a été envoyé.';
} else {
echo 'Le e-mail n\'a pu être envoyé';
}

} else {
// Affichage du formulaire
print "
<form action='' method='post' id='information' name='information' style='font-size:12px;color:#fff;' onSubmit=\"return valider();\">
<img src='img/titre-fcX.jpg' alt='' style='margin-bottom:20px;' />
<div style=' padding-bottom:5px; color:#000;'>
<strong><em>lapins bleus formation</em> et <em>Apple</em> vous invitent à découvrir Final Cut Pro X la semaine du 21 au 25 novembre.</strong><br />
<br />
Loic Gagnant, formateur Final Cut Pro agréé Apple T3, explorera avec vous la nouvelle interface du logiciel, sa méthodologie inédite, ses outils d'animation et de colorimétrie perfectionnés et son tout nouveau système de classification, d'analyse et de tris des médias. <br />
<br />
<strong>5 sessions organisées du lundi 21 au vendredi 25, de 14h à 17h.</strong>
<br />
<strong>Entrée libre / Places limitées !</strong>
<br /><br /> <br />
</div>
<!-- -->


<div style='font-size:16px; font-weight:bold; padding-bottom:5px; padding-top:0px; color:#000;'>Choisissez votre date :</div><br />
<div style='width:260px; height:230px; background:url(img/fond-formulaire-big2.jpg) no-repeat top left; padding:20px;>
";

print "
<div style='padding-left:20px'; >Lundi 21 novembre
<input type='radio' name='choix' value=oui style='margin-left:36px;'><br /><br />
Mardi 22 novembre
<input type='radio' name='choix' value=oui style='margin-left:37px;'><br /><br />
Mercredi 23 novembre
<input type='radio' name='choix' value=oui style='margin-left:20px;'><br /><br />
Jeudi 24 novembre
<input type='radio' name='choix' value=oui style='margin-left:37px;'><br /><br />
Vendredi 25 novembre
<input type='radio' name='choix' value=oui style='margin-left:20px;'><br /><br />
<!--<div style='width:200px; height:235px; background:url(img/fond-formulaire-big2.jpg) no-repeat top left; padding:20px;>-->
<div style='margin-top:20px;'>Votre adresse e-mail :<input type='text' value='' id='email' name='email' style='margin-left:20px;'/></div>
</div>

<br />
<div style='width:135px;height:30px; float:right;'><input type='submit' id='submit' name='submit' value='' style='width:77px;height:30px;background:url(img/btn-envoyer.jpg) no-repeat;border:0 none; margin-left:0px; margin-top:15px' /></div>


<input type='hidden' id='envoi' name='envoi' value='ok' />
</form>


";

}
print "


</div>


Messages dans ce sujet

Atteindre :


Utilisateur(s) parcourant ce sujet : 1 visiteur(s)