請(qǐng)問我這里哪里有問題?輸出結(jié)果沒有天數(shù)
<script>????? ??window.onload?=?function(){ var?timedate=?new?Date('2018,8,1');?????//自定義結(jié)束時(shí)間?? var?now?=??new?Date?();????//獲取當(dāng)前時(shí)間 var?date?=?timedate.getTime()?-?now.getTime();????//得出的為毫秒 var?time?=?Math.ceil(date/(1000*60*60*24))?;??//1000?*?60?*?//60?*?24一天的秒數(shù) ????if(time?>?0?){ ??????document.getElementById('timeShow').innerHTML?=?time; ?} ????} </script>
2018-07-03
有沒有?? timeShow? 這個(gè)dom節(jié)點(diǎn)???