收藏本站 收藏本站
积木网首页 - 软件测试 - 常用手册 - 站长工具 - 技术社区
积木学院 > 程序开发 > jQuery > 正文

两个Javascript小tip资料

来源:互联网 日期:2014-11-15 18:48
1. 定时循环执行代码
 
window.setInterval(function() {
$.get("service.aspx?method=unreadmessage", function(data) {
if (data != "0")
$('#unreadCount').html(data).show();
else
$('#unreadCount').hide();

});
}, 1000);可以类似这样写。



2. 刷新当前页面
 
window.location.reload();

推荐阅读

 

热点信息

 
强悍的草根IT技术社区,这里应该有您想要的!
Copyright © 2010 Gimoo.Net. All Rights Rreserved  京ICP备05050695号