Bonjour,
je suis debutant en html et le formulaire dont le code suit ne procede pas aux verifications qu'il devrait operer avec le script en javascript.
Qqu'un pourrait il eclairer ma lanterne ,grand merci par avance et pardonnez les maladresses c'est tres tres nouveau pour moi..



Code : Sélectionner tout - Visualiser dans une fenêtre à part
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
76
77
78
79
80
81
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html><head>
<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type"><title>YAPH </title>
 
<link media="screen" type="text/css" href="styles/styles.css" rel="stylesheet">
<script language="javascript">
function checkForm() {
var input = document.saisieTicketForm.oneLiner;
if ( input.value.length == 0 ) {
alert("Vous n'avez pas saisi de résumé");
input.focus();
return false;
}
var selectApp = document.saisieTicketForm.application;
input = document.saisieTicketForm.applicationOther;
if ( selectApp.value == -1 && input.value.length == 0 ) {
alert("Vous devez saisir le nom de l'application si vous n'en choisissez pas une dans la liste");
input.focus();
return false;
}
return true;
}
</script>
</head>
<body>
<form name="saisieTicket" style="width: 815px;" action="mailto:el---che@hotmail.fr" method="post" enctype="multipart/form-data" onsubmit="return checkForm()">
<table style="text-align: left; height: 400px; width: 600px;" border="1" cellpadding="2" cellspacing="2">
<tbody>
<tr>
<td style="text-align: center; background-color: rgb(255, 204, 0); height: 20px; font-size: 14px; font-weight: bold; width: 662px;" colspan="2">Veuillez decrire votre demande d'intervention</td>
</tr>
 
<tr class="tab_bg_1" tr="">
<td style="height: 30px; width: 662px;">Application:</td>
<td style="width: 519px; height: 30px; vertical-align: middle;">
<select name="application" ;=""><option value="-1">--Autres--</option><option value="0">windaube</option></select>
<input size="55" name="application other">
</td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="height: 30px; width: 662px;">Priorité:</td>
<td style="width: 519px; height: 30px;">
<select name="priority"><option value="-1">moyenne</option><option value="1">haute</option></select>
 
</td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="height: 30px; width: 662px;">Type:</td>
<td style="width: 519px; height: 30px;">
<input checked="checked" name="type" value="anomalie" type="radio">Anomalie<input name="type" value="evolution" type="radio">Demande
d'évolution
</td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="height: 30px; width: 662px;">Résumé:</td>
<td style="width: 519px; height: 30px;">
<input size="80" name="onLiner"></td>
</tr>
<tr class="tab_bg_1" tr="">
 
<td style="height: 20px; width: 662px;" colspan="2">Description
détaillée:</td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="text-align: center; height: 163px; width: 662px;" colspan="2"><textarea cols="60" rows="14" name="contents"></textarea> </td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="height: 30px; width: 662px;">Pièce-jointe:</td>
<td style="width: 519px; height: 30px;">
<input name="MAX_FILE_SIZE" value="3000" type="hidden"><input name="piecejointe" size="25" type="file"></td>
</tr>
<tr class="tab_bg_1" tr="">
<td style="text-align: right; height: 30px; width: 662px;" colspan="2"><input value="Envoyer" type="submit">
</td>
 
</tr>
</tbody>
</table>
<br>
</form>
</body></html>