'readablizeBytes': function (bytes) { var s = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB']; var e = Math.floor(Math.log(bytes) / Math.log(1024)); return (bytes / Math.pow(1024, Math.floor(e))).toFixed(2) + " " + s[e]; }
将字节转化成其他单位
最新推荐文章于 2022-05-24 19:18:09 发布