voici le tag wipub a inserer.
<img border=0 src="http://www.wipub.com/formulaire.php?id_annonceur=999&email=EMAIL" width=1 height=1>
et voici mon formulaire qui marche tres bien.<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>formulaire</title>
</head>
<body><?php
$email_dest = "******@hotmail.com";
if ($_POST['envoi']) {
$message_remerciement = "merci";
// E-mail headers:
$headers ="MIME-Version: 1.0 \n";
$headers .="From: ***@******** \n";
$headers .="Content-Type: text/html; charset=iso-8859-1 \n";
$subject = "client";
$partie_entete = "<html><head>
<meta http-equiv=Content-Type content=text/html; charset=iso-8859-1>
</head>
<body bgcolor=#FFFFFF>";
for ($a=1; $a<= $_POST['nbre_champs_texte']; $a++) {
$partie_champs_texte .= "<font face='Verdana' size='2' color='#003366'>" . $_POST['titre_champ'.$a] . " = " . $_POST['champ'.$a] . "</font><br>";
}
if ($_POST['nbre_zone_email'] != 0) {
$partie_zone_email = "<font face='Verdana' size='2' color='#003366'>" . $_POST['titre_email'] . " = " . $_POST['zone_email'] . "</font><br>";
}
if ($_POST['nbre_zones_texte'] != 0) {
$partie_zone_texte = "<font face='Verdana' size='2' color='#003366'>" . $_POST['titre_zone'] . " = " . $_POST['zone_texte'] . "</font><br>";
$partie_zone_texte = stripslashes($partie_zone_texte);
}
$fin = "</body></html>";
$sortie = $partie_entete . $partie_champs_texte . $partie_zone_email . $partie_zone_texte . $fin;
// Send the e-mail
if (@!mail($email_dest,$subject,$sortie,$headers)) {
echo("Envoi du formulaire impossible");
} // Closing if !mail...
} // Closing if edit
?><html>
<head>
<title>reponse formulaire</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript"><!-- Hide script from older browsers
function verifSelection() {if (mail_form.champ1.value == "") {
alert("Merci d'indiquer VOTRE NOM ET PRENOM")
return false
} if (mail_form.champ2.value == "") {
alert("Merci d'indiquer VOTRE SEXE")
return false
} if (mail_form.champ3.value == "") {
alert("Merci d'indiquer VOTRE ADRESSE")
return false
} if (mail_form.champ4.value == "") {
alert("Merci d'indiquer VOTRE CODE POSTAL")
return false
} if (mail_form.champ5.value == "") {
alert("Merci d'indiquer VOTRE VILLE")
return false
} if (mail_form.champ6.value == "") {
alert("Merci d'indiquer VOTRE PAYS")
return false
} if (mail_form.champ8.value == "") {
alert("Merci d'indiquer AU MOINS UN NUMERO DE TELEPHONE")
return false
} if (mail_form.champ12.value == "") {
alert("Merci d'indiquer VOTRE POIDS")
return false
} if (mail_form.champ13.value == "") {
alert("Merci d'indiquer VOTRE MOTIVATION A PERDRE DU POIDS")
return false
} if (mail_form.champ14.value == "") {
alert("Merci d'indiquer COMBIEN DE KILOS VOUS VOULEZ PERDRE")
return false
} if (mail_form.champ18.value == "") {
alert("Merci d'indiquer LE NOMBRE DE REPAS JOURNALIER")
return false
} if (mail_form.champ19.value == "") {
alert("Merci d'indiquer LE COUT DE VOS REPAS JOURNALIER")
return false
} if (mail_form.zone_email.value == "") {
alert("Merci d'indiquer VOTRE EMAIL")
return false
}
invalidChars = " /:,;'"
for (i=0; i<invalidChars.length; i++) { // does it contain any invalid characters?
badChar = invalidChars.charAt(i)
if (mail_form.zone_email.value.indexOf(badChar,0) > -1) {
alert("Votre adresse e-mail contient des caractères invalides. Veuillez vérifier.")
mail_form.zone_email.focus()
return false
}
}
atPos = mail_form.zone_email.value.indexOf("@",1) // there must be one "@" symbol
if (atPos == -1) {
alert('Votre adresse e-mail ne contient pas le signe "@". Veuillez vérifier.')
mail_form.zone_email.focus()
return false
}
if (mail_form.zone_email.value.indexOf("@",atPos+1) != -1) { // and only one "@" symbol
alert('Il ne doit y avoir qu\'un signe "@". Veuillez vérifier.')
mail_form.zone_email.focus()
return false
}
periodPos = mail_form.zone_email.value.indexOf(".",atPos)
if (periodPos == -1) { // and at least one "." after the "@"
alert('Vous avez oublié le point "." après le signe "@". Veuillez vérifier.')
mail_form.zone_email.focus()
return false
}
if (periodPos+3 > mail_form.zone_email.value.length) { // must be at least 2 characters after the
alert('Il doit y avoir au moins deux caractères après le signe ".". Veuillez vérifier.')
mail_form.zone_email.focus()
return false
}} // Fin de la fonction
</script>
</head>
<body>
<?php
if ($message_remerciement) {
echo("<font face=Verdana size=2>");
echo(stripslashes($message_remerciement));
echo("</p></body></html>");
exit();
}
?>
<form name="mail_form" method="post" action="<?=$PHP_SELF?>" onSubmit="return verifSelection()">
<div align="center">
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><div align="left"><strong><font face="Verdana" size="2">Nom et prénom:</font></strong></div></td>
<td width="315"><div align="left">
<strong>
<input name="champ1" type="text">
</strong></div></td>
</tr>
</table>
</div>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155" height="24"><font face="Verdana" size="2"><strong>Sexe :</strong></font></td>
<td width="315"><strong>
<input name="champ2" type="radio" value="homme" checked>
Homme
<input name="champ2" type="radio" value="femme">
Femme</strong></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td><font face="Verdana" size="2"><strong>Email :</strong></font></td>
<td><input name="zone_email" type="text"></td>
</tr>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Adresse :</strong></font></td>
<td width="315"><input name="champ3" type="text"></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Code postal :</strong></font></td>
<td width="315"><input name="champ4" type="text"></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Ville :</strong></font></td>
<td width="315"><input name="champ5" type="text"></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Pays :</strong></font></td>
<td width="315"><input name="champ6" type="text"></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Langue :</strong></font></td>
<td width="315"> <select name="champ7" id="champ7">
<option selected>Sélectionner</option>
<option>Français</option>
<option>Espagnol</option>
<option>Anglais</option>
<option>Italien</option>
<option>Allemand</option>
<option>Portugais</option>
<option>Chinois</option>
<option>Hindi</option>
<option>Urdu</option>
<option>Coreen</option>
<option>Japonais</option>
<option>Thai</option>
<option>Philippin</option>
<option>Danois</option>
<option>Grec</option>
<option>Hongrois</option>
<option>Indonesien</option>
<option>Hebreu</option>
<option>Arabe</option>
<option>Russe</option>
<option>Turks</option>
<option>Autre</option>
</select></td></tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Téléphone :</strong></font></td>
<td width="315"><input name="champ8" type="text"></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Le mieux joignable: </strong></font></td>
<td width="315"><select name="champ9" id="champ9">
<option selected>Sélectionner</option>
<option>Matin</option>
<option>Midi</option>
<option>Soir</option>
</select></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Age :</strong></font></td>
<td width="315"><select name="champ10" id="champ10">
<option selected>Sélectionner</option>
<option>moins de 18 ans</option>
<option>18-20 ans</option>
<option>21-25 ans</option>
<option>26-30 ans</option>
<option>31-35 ans</option>
<option>36-40 ans</option>
<option>41-45 ans</option>
<option>46-50 ans</option>
<option>51-55 ans</option>
<option>56-60 ans</option>
<option>61-65 ans</option>
<option>66-70 ans</option>
<option>71-75 ans</option>
<option>76 ans et +</option>
</select></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Hauteur :</strong></font></td>
<td width="315"><select name="champ11" id="champ11">
<option selected>Sélectionner</option>
<option>Moins que 150 cm</option>
<option>150 cm</option>
<option>151 cm</option>
<option>152 cm</option>
<option>153 cm</option>
<option>154 cm</option>
<option>155 cm</option>
<option>156 cm</option>
<option>157 cm</option>
<option>158 cm</option>
<option>159 cm</option>
<option>160 cm</option>
<option>161 cm</option>
<option>162 cm</option>
<option>163 cm</option>
<option>164 cm</option>
<option>165 cm</option>
<option>166 cm</option>
<option>167 cm</option>
<option>168 cm</option>
<option>169 cm</option>
<option>170 cm</option>
<option>171 cm</option>
<option>172 cm</option>
<option>173 cm</option>
<option>174 cm</option>
<option>175 cm</option>
<option>176 cm</option>
<option>177 cm</option>
<option>178 cm</option>
<option>179 cm</option>
<option>180 cm</option>
<option>181 cm</option>
<option>182 cm</option>
<option>183 cm</option>
<option>184 cm</option>
<option>185 cm</option>
<option>186 cm</option>
<option>187 cm</option>
<option>188 cm</option>
<option>189 cm</option>
<option>190 cm</option>
<option>191 cm</option>
<option>192 cm</option>
<option>193 cm</option>
<option>194 cm</option>
<option>195 cm</option>
<option>196 cm</option>
<option>197 cm</option>
<option>198 cm</option>
<option>199 cm</option>
<option>200 cm</option>
<option>201 cm</option>
<option>202 cm</option>
<option>203 cm</option>
<option>204 cm</option>
<option>205 cm</option>
<option>206 cm</option>
<option>207 cm</option>
<option>208 cm</option>
<option>209 cm</option>
<option>210 cm</option>
<option>plus de 210 cm</option>
</select></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2"><strong>Poids :</strong></font></td>
<td width="315"><input name="champ12" type="text" size="10">
<strong> Kg</strong></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="342"><font face="Verdana" size="2"><strong>Etes-vous motivé pour perdre du poids? </strong></font></td>
<td width="128"><input name="champ13" type="radio" value="oui" checked>
oui
<input name="champ13" type="radio" value="non">
non</td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="342"><font face="Verdana" size="2"><strong>Si Oui, combien de Kg souhaitez-vous perdre?</strong></font></td>
<td width="128"><input name="champ14" type="text" size="10">
Kg</td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td><p><font face="Verdana" size="2"><strong>Qu'avez-vous déjà essayé au préalable et comment cela a-t-il fonctionné pour vous ? (soyez spécifique)</strong></font></p>
<p>
<textarea name="champ15" cols="40" rows="3"></textarea>
</p></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td height="123"><p><font face="Verdana" size="2"><strong>Quelle est la raison qui vous motive le plus pour perdre du poids maintenant ?</strong></font></p>
<p>
<textarea name="champ16" cols="40" rows="3"></textarea>
</p></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td height="107"><p><font face="Verdana" size="2"><strong>Avez-vous des problèmes de santé?</strong></font></p>
<p>
<textarea name="champ17" cols="40" rows="3"></textarea>
</p></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td height="56"><p><font face="Verdana" size="2"><strong>Combien de repas mangez-vous par jour?</strong></font> </p>
<p>
<strong>
<input name="champ18" type="radio" value="1" checked>
1
<input name="champ18" type="radio" value="2">
2
<input name="champ18" type="radio" value="3">
3
<input name="champ18" type="radio" value="4">
4 et +</strong></p></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td height="72"><p align="left"><font face="Verdana" size="2"><strong>Combien pensez-vous que ces repas vous coûtent sur une base journalière?</strong></font></p>
<p align="left">
<input name="champ19" type="radio" value="" checked>
<strong>2€
<input name="champ19" type="radio" value="">
4€
<input name="champ19" type="radio" value="">
6€
<input name="champ19" type="radio" value="">
8€
<input name="champ19" type="radio" value="">
10 et + </strong> </p></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="156"><font face="Verdana" size="2">Quand seriez vous seriez-vous prêt(e) à démarrer ? </font></td>
<td width="314"><select name="champ20" id="champ20">
<option selected>Sélectionner</option>
<option>Maintenant</option>
<option>Dans la semaine</option>
<option>Dans 30 jours</option>
</select></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center"> </p>
<tr>
<td width="155"><font face="Verdana" size="2">Ou avez-vous trouvé notre site Web?</font></td>
<td width="315"><select name="champ21" id="champ21">
<option selected>Sélectionner</option>
<option>Annonce journal</option>
<option>Affiche</option>
<option>Flyer</option>
<option>Supermarché</option>
<option>internet</option>
<option>Carte de visite</option>
<option>Enquête</option>
<option>Google</option>
<option>Emailing</option>
<option>Suggestion d'un ami</option>
<option>Autre</option>
</select></td>
</tr>
</table>
<table width="480" border="0" align="center">
<p align="center">
</p><tr>
<td width="226" valign="top"><input name="nbre_champs_texte" type="hidden" id="nbre_champs_texte" value="21">
<input name="nbre_zones_texte" type="hidden" value="0">
<input name="nbre_zone_email" type="hidden" value="1">
<input name="titre_champ1" type="hidden" value="Nom et prénom:"><input name="titre_champ2" type="hidden" value="Sexe :"><input name="titre_champ3" type="hidden" value="Adresse :"><input name="titre_champ4" type="hidden" value="Code postal :"><input name="titre_champ5" type="hidden" value="Ville :"><input name="titre_champ6" type="hidden" value="Pays :"><input name="titre_champ7" type="hidden" value="Langue :"><input name="titre_champ8" type="hidden" value="Téléphone :"><input name="titre_champ9" type="hidden" value="Le mieux joignable: "><input name="titre_champ10" type="hidden" value="Age :"><input name="titre_champ11" type="hidden" value="Hauteur :"><input name="titre_champ12" type="hidden" value="Poids :"><input name="titre_champ13" type="hidden" value="Etes-vous motivé pour perdre du poids? "><input name="titre_champ14" type="hidden" value="Si Oui, combien de Kg souhaitez-vous perdre?"><input name="titre_champ15" type="hidden" value="Qu'avez-vous déjà essayé au préalable et comment cela a-t-il fonctionné pour vous ? (soyez spécifique)"><input name="titre_champ16" type="hidden" value="Quelle est la raison qui vous motive le plus pour perdre du poids maintenant ? "><input name="titre_champ17" type="hidden" value="Avez-vous des problèmes de santé? "><input name="titre_champ18" type="hidden" value="Combien de repas mangez-vous par jour?"><input name="titre_champ19" type="hidden" value="Combien pensez-vous que ces repas vous coûtent sur une base journalière?"><input name="titre_champ20" type="hidden" value="Quand seriez vous seriez-vous prêt(e) à démarrer ? "><input name="titre_champ21" type="hidden" value="Ou avez-vous trouvé notre site Web?"><input name="titre_email" type="hidden" value="Email :"></td>
<td width="244"><div align="center">
<input type="reset" name="Reset" value="Effacer">
<input type="submit" name="envoi" value="Envoyer">
</div></td>
</tr>
</table>
<div align="center"></div>
</form>
</body>
</html>
</body>
</html>