Quisiera saber si se puede enviar el valor de una variable javascript al form para poder enviarla despues, asi como en el ejemplo la variable plaso_entrega, que es 1 o 0 si es chequeada o no. Gracias!!
Código PHP:
<html>
<head>
<script language="JavaScript">
<!--
function Validar(principal){
var pos1, pos2, bOk = true;
var plaso_entrega,plaso_pago;
//VERIFICA PLASO DE ENTREGA
if (document.principal.entrega1.checked){
//se verifica que este la clave en el input
plaso_entrega=1;
}
else{
plaso_entrega=0;
}
}
-->
</script>
<title>Validar Campo Vacio</title>
</head>
<body>
<form name="principal" method="post" action="entrega.php">
<input type="checkbox" name="entrega1">chequea
<input type="hidden" value=plaso_entrega>
<input type="submit" name="Validar" value="Validar" onclick="Validar()">
</form>
</body>
</html>