abstract:<!DOCTYPE html><html><head><title></title><style type="text/css">* {margin:0;padding: 0;}div {font-size:36px; width:1200px; height: 180px; margin:0 auto;
<!DOCTYPE html>
<html>
<head>
<title></title>
<style type="text/css">
* {margin:0;padding: 0;}
div {font-size:36px; width:1200px; height: 180px; margin:0 auto; background: #82d743;line-height:180px; text-align: center; color:#fff;}
</style>
<script type="text/javascript" src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
</head>
<body>
<div>
<p>51倒计时:<span></span></p>
</div>
<script type="text/javascript">
$(function(){
function Ro(){
var date = Date.parse("05,01,2019");//得到指定日期的毫秒数
var d = new Date();
var dd =d.getTime();//得到当前毫秒数
var rd = Math.floor((date-dd)/1000); //得到总秒数。
var days =Math.floor(rd/86400);
var hours =Math.floor(rd%86400/3600);
var minus =Math.floor((rd%3600)/60);
var second =Math.floor(rd%60);
$('span').text(days+'天'+hours+'小时'+minus+'分钟'+second+'秒');
}
setInterval(Ro,1000);
})
</script>
</body>
</html>