当前位置: 首页 > 工具软件 > timeago > 使用案例 >

jquery【插件】 timeago的使用

林龙野
2023-12-01
作者:zccst


<script type="text/javascript" src="jquery-1.7.1.js"></script>
<script type="text/javascript" src="jquery.timeago.js"></script>
<script type="text/javascript" src="timeago.ch.js"></script>
<title>时间格式化</title>
<style type="text/css">
.a{ width:200px; height:100px; background-color:#FC9}
</style>
<script type="text/javascript">
jQuery(document).ready(function() {
jQuery("abbr.timeago").timeago();
//jQuery("div.timeago").timeago();
});
</script>
</head>

<div class="a timeago"></div>
<abbr class="timeago" title="2012-03-01 14:16:35"></abbr>
<abbr class="timeago" title="2012-03-09 14:16:35"></abbr>



官方网站:http://timeago.yarp.com/
 类似资料: