<script>
function doAAA(){
var a = '1,2,3.001';
var c = a.split("");
var num="";
for(i=0;i<c.length;i++){
if(c[i]!=","){
num=num+c[i];
}
}
alert(num);
}
</script>
<script language="javascript">
function ParseMoney(str)
{
var idx = str.indexOf(".");
while (str.substring(0, idx++).length % 3)
{
str = "0" + str;
}
return str.replace(/(/d{3})/g, "$1,").replace(/,/./, ".").replace(/(^0*)|(,$)/g, "");
}
</script>