|
楼主 |
发表于 2015-6-1 15:35:00
|
显示全部楼层
四川省宜宾市
javascript (“function 加法运算(a,b){return +a+parseInt(b);}”)返回 (调用javascript (“加法运算”, 到文本 (a ), 到文本 (b )) )javascript (“function 取现行时间(){var d = new Date(); var ret=d.getFullYear()+'/';ret+=('00'+(d.getMonth()+1)).slice(-2)+'/';ret+=('00'+d.getDate()).slice(-2)+' ';ret+=('00'+d.getHours()).slice(-2)+':';ret+=('00'+d.getMinutes()).slice(-2)+':';ret+=('00'+d.getSeconds()).slice(-2); if(1){ return ret;}else { return 10}} ”)返回 (到时间 (调用javascript (“取现行时间”, “null”)) )javascript (“function 取随机的数(limit){return Math.floor(Math.random()*limit);}”)返回 (调用javascript (“取随机的数”, 最大值 )) javascript (“function 是否为数字(inputString){return (!isNaN(parseInt(inputString))) ? 1 : 0;}”)返回 (调用javascript (“是否为数字”, STRING )) javascript (“function 取文本的长度(inputString){ return inputString.length;}”)返回 (调用javascript (“取文本的长度”, STRING )) javascript (“function 十六到十(hex) { return parseInt(hex,16); }”)返回 (调用javascript (“十六到十”, STRING )) javascript (“function 十到十六(dec){var hexStr = '0123456789ABCDEF';var low = dec % 16;var high = (dec - low)/16;var high = (dec - low)/16;hex = '' + hexStr.charAt(high) + hexStr.charAt(low);return hex;}”)返回 (调用javascript (“十到十六”, STRING )) |
|