Ver Mensaje Individual
  #1 (permalink)  
Antiguo 08/05/2010, 04:24
iggy1995
 
Fecha de Ingreso: junio-2009
Mensajes: 14
Antigüedad: 14 años, 10 meses
Puntos: 0
Multiplicar el total

Hola buenas tengo este codigo:
Código PHP:
<script>  
function 
calcular(campo) {  
 
frm=campo.form;  
 var 
prod=0;  
 var 
y=0;  
 while (
typeof frm.elements["c"+y]!="undefined") {  
 var 
o=frm.elements["c"+y];  
 var 
x=0
 while (!
o[x].checked) { x++; }  
 
prod+=parseFloat(o[x].value);  
 
y++;  
 }  
 
document.getElementById("resultado").text;  
}  
  
</script> 
<input name="c0" type="radio" onclick="calcular(this)" value="1000" /> 
<input value="1050" type="radio" name="c0" onclick="calcular(this)" /> 
<table width="84" border="0"> 
                  <tr> 
                    <td width="52"><table width="54"> 
                        <tr> 
                          <td width="34">Total: </td> 
                          <td width="10" id="resultado">0</td> 
                        </tr> 
                    </table></td> 
                    <td width="101">&euro; </td> 
                  </tr> 
                </table> 
Quisiera saber si el total ("resultado") se podria multiplicar por 1.16, calculando un numero que quedaria debajo.

Ejemplo:

800*
1.16
-------
928


Gracias de antemano