問if(time<12){? ? x="早上好";}
VM1817:1 Uncaught ReferenceError: 時(shí)間未定義于 :1:1
var a=new Date()
time=a.getHours()
給time賦值就好了