Slt,
J' ai un probleme dans l' �valuation des checkbox g�n�r�s dynamiquement au cas ou il y a UN SEUL CHECKBOX a �t� g�n�r�.
Voici document+script qui fonctione(selectione tous les Checkbox) s' il y a plus un checkbox dans le Formulaire.
Comment faire s' il un seul checkbox qui a �t� g�n�r�?.(je ne pas utiliser ID sur les checbox, elle seront g�n�r� dynamiquement)
Aidez moi c' est tr�s important!!![]()
![]()
![]()
![]()
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>The Modal Content</title>
<script type="text/javascript">
function checkAll()
{
selectedItems=document.forms[0].selectedItems
for(i = 0; i < selectedItems.length; i++)
{
box = eval(selectedItems[i+1]);
if (box.checked == false)
{
box.checked = true;
}
}
}
</script>
</head>
<body>
<h3>Projekt Drucken</h3>
<form id="myForm">
<input type="checkbox" name="selectedItems" value="messages" ID="Checkbox10">Mitteilungen<br />
<br />
<input type=button value="alle" onClick="javascript:checkAll();" ID="Button1" NAME="Button1">
</form>
</body>
</html>
Partager