Ver Mensaje Individual
  #3 (permalink)  
Antiguo 11/02/2003, 13:12
Avatar de Mickel
Mickel
 
Fecha de Ingreso: mayo-2002
Ubicación: Lima, Peru
Mensajes: 4.619
Antigüedad: 22 años
Puntos: 7
Aca te paso una funcion que te puede orientar
Código PHP:
function CheckNumber(fieldNamefieldValuedecimalsmdefault) {
if (
isNaN(fieldValue)) {
    
fieldName.value=mdefault;
} else {
    
timeshundred=parseFloat(fieldValue Math.pow(10decimals));
    
integervalue=parseInt(parseFloat(fieldValue) * Math.pow(10decimals));
    if (
timeshundred != integervalue) {
        
fieldName.value=mdefault;
      }
}