function noteRunTime(msg){
var fso, tf;
var d, timeHead = "运行在: ";
var c = ":";
d = new Date();
timeHead += d.getHours() + c;
timeHead += d.getMinutes() + c;
timeHead += d.getSeconds() + c;
timeHead += d.getMilliseconds();
fso = new ActiveXObject("Scripting.FileSystemObject");
tf = fso.OpenTextFile("d:\\htmlRunTime.log", 8,true);
tf.WriteLine(msg + "[" + timeHead + "]" + "(ss)") ;
tf.WriteBlankLines(1);
tf.Close();
}
|
输出js执行时间
最新推荐文章于 2023-12-21 16:29:06 发布