Ver Mensaje Individual
  #3 (permalink)  
Antiguo 28/06/2012, 10:43
Zipus
 
Fecha de Ingreso: junio-2010
Mensajes: 106
Antigüedad: 14 años, 7 meses
Puntos: 1
Respuesta: Error en Javascript

Como ya he dicho podria ser un pequeño error, y así es!

Se trataba de cambiar un error de tipografia dentro de la funcion.
Hos dejo el codigo para que no tengais dudas... :)

Código Javascript:
Ver original
  1. function calcular_maiz() {
  2.     var precio_maiz = document.maiz.precio_maiz.value;
  3.     var divisa_maiz = document.maiz.divisa_maiz.value;
  4.     var co_doll_maiz = (precio_maiz / 100) * 5000;
  5.     var tm_doll_maiz = co_doll_maiz / 127;
  6.     var co_euro_maiz = co_doll_maiz / divisa_maiz;
  7.     var tm_euro_maiz = co_euro_maiz / 127;
  8.     document.getElementById('co_doll_maiz').innerHTML = co_doll_maiz;
  9.     document.getElementById('tm_doll_maiz').innerHTML = tm_doll_maiz;
  10.     document.getElementById('co_euro_maiz').innerHTML = co_euro_maiz;
  11.     document.getElementById('tm_euro_maiz').innerHTML = tm_euro_maiz;
  12.   }