1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75
| <!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head><title>Formulaire d'ajout d'un abonné adulte</title>
<script language="JavaScript">
<!--
function couleur(obj) {
obj.style.backgroundColor = "#FFFFFF";
}
function check() {
var msg = "";
if (document.formulaire.email.value != "") {
indexAroba = document.formulaire.email.value.indexOf('@');
indexPoint = document.formulaire.email.value.indexOf('.');
if ((indexAroba < 0) || (indexPoint < 0)) {
document.formulaire.email.style.backgroundColor = "#F3C200";
msg += "Le mail est incorrect\n";
}
}
else {
document.formulaire.email.style.backgroundColor = "#F3C200";
msg += "Veuillez saisir votre mail.\n";
}
if (document.formulaire.nom.value == "") {
msg += "Veuillez saisir votre nom\n";
document.formulaire.nom.style.backgroundColor = "#F3C200";
}
if (document.formulaire.prenom.value == "") {
msg += "Veuillez saisir votre prenom\n";
document.formulaire.prenom.style.backgroundColor = "#F3C200";
}
if (msg == "") return(true);
else {
alert(msg);
return(false);
}
}
//-->
</script> </head>
<body>
<center><img src="telecom_bretagne.jpg" height="100" width="100"></center>
<center><h1>Formulaire d'ajout d'un abonné adulte</h1></center>
<form method="post" enctype="application/x-www-form-urlencoded" name="formulaire" onSubmit="return check();">
<center>
<table>
<tr><td>Nom</td><td>
<input type="text" name="nom" onKeyUp="javascript:couleur(this);">
<tr><td>Prénom</td><td>
<input type="text" name="prenom" onKeyUp="javascript:couleur(this);">
<tr><td>Adresse Postale</td><td>
<input type="text" name="adressePostale" onKeyUp="javascript:couleur(this);">
<tr><td>Email</td><td>
<input type="text" name="email" onKeyUp="javascript:couleur(this);">
<tr><td>Date de naissance (dd/mm/yyyy)</td><td>
<input type="text" name="dateNaissance" onKeyUp="javascript:couleur(this);">
<tr><td>Date Fin Abonnement (dd/mm/yyyy)</td><td>
<input type="text" name="dateFinAbonnement" onKeyUp="javascript:couleur(this);">
</table>
<br>
<center><input type="submit" value="Insérer !"></center>
</center>
</form>
</body>
</html> |
Partager