Ver Mensaje Individual
  #6 (permalink)  
Antiguo 05/03/2009, 10:46
Avatar de JavierB
JavierB
Colaborador
 
Fecha de Ingreso: febrero-2002
Ubicación: Madrid
Mensajes: 25.052
Antigüedad: 23 años, 1 mes
Puntos: 772
Respuesta: arreglo de checkbox y su validacion

Hola GREGgraffin

A ver si este ejemplo te sirve de ayuda:

Código javascript:
Ver original
  1. <html>
  2. <head>
  3. <script type="text/javascript">
  4. function marcar(obj) {
  5.   chk = obj.parentNode.getElementsByTagName('input');
  6.   for (i=0; ele=chk[i]; i++)
  7.     ele.checked = obj.checked;
  8. }
  9. </script>
  10. </head>
  11. <body>
  12. <div>
  13. Marcar Renault: <input type="checkbox" onclick="marcar(this)" /><br />
  14. <input type="checkbox" />
  15. <input type="checkbox" />
  16. <input type="checkbox" />
  17. </div>
  18. <div>
  19. Marcar Volvo: <input type="checkbox" onclick="marcar(this)" /><br />
  20. <input type="checkbox" />
  21. <input type="checkbox" />
  22. <input type="checkbox" />
  23. </div>
  24. </body>
  25. </html>

Saludos,