function Changechinesenumber (num) {if (IsNaN (num) | | num > Math.pow (TEN)) return "" var cn = "0 One and three restaurants Woolu Qi Ba Jiu var unit = new Array ("Pick Baiqian", "split angle") var unit1= new Array ("trillion", "") var Numarray = Num.tostring (). Split ("." ) var start = new Array (numarray[0].length-1, 2) function Tochinese (num, index) {var num = num.re Place (/\d/g, function ($) {return Cn.charat ($) +unit[index].charat (start--%4? start%4:-1) }) return num} for (var i=0; i<numarray.length; i++) {var tmp = ' "for (Var j=0; j*4<numarray[i].length; J + +) {var strindex = numarray[i].length-(j+1) var str = numarray[i].substring (strindex, strindex+4) var start = I? 2:str.length-1 var tmp1 = Tochinese (str, i) TMP1 = tmp1.replace (/(0.) +/g, "0"). Replace (/0 +$/, "") Tmp1 = Tmp1.replace (/^ one pick/, "pickup") TMP = (Tmp1+unit1[i].charat (j-1)) + tmp} Numarray[i] = tmp} numarray[1] = numarray[1]? NUMARRAY[1]: "numarray[0] = numarray[0]? numarray[0]+ "meta": numarray[0], numarray[1] = Numarray[1].replace (/^ 0 +/, "") numarray[1] = Numarray[1].match (/min/)? NUMARRAY[1]: numarray[1]+ "whole" return numarray[0]+numarray[1]}
JS Convert page lowercase amount to uppercase amount