日期:2014-05-16 浏览次数:20555 次
var c=123.444 c=.toFixed(2)
------解决方案--------------------
var c=parseFloat(a.toFixed(2))+parseFloat(b.toFixed(2));
------解决方案--------------------
function ja(){
var a=document.getElementById("a1").value;
var b=document.getElementById("a2").value;
var c=parseFloat(a)+parseFloat(b);
document.getElementById("a6").value=parseFloat(c).toFixed(2);
}
------解决方案--------------------
function ja(){
var a=document.getElementById("a1").value;
var b=document.getElementById("a2").value;
var c=parseFloat(a)+parseFloat(b);
document.getElementById("a6").value=parseFloat(c).toFixed(2);
}