
jquery & js
请叫我砖家
这个作者很懒,什么都没留下…
展开
-
window.location href replace 区别
1.window.location.href=“url”:改变url地址; 2.window.location.replace(“url”):将地址替换成新url,该方法通过指定URL替换当前缓存在历史里(客户端)的项目,因此当使用replace方法之后,你不能通过“前进”和“后 退”来访问已经被替换的URL,这个特点对于做一些过渡页面非常有用!转载 2014-03-22 20:51:39 · 990 阅读 · 0 评论 -
谷歌Chrome浏览器下document.documentElement.scrollTop取值异常的解决方法
var scroll_top; if (document.documentElement && document.documentElement.scrollTop) { scroll_top = document.documentElement.scrollTop; } else if (document.b转载 2014-05-12 13:19:11 · 1270 阅读 · 0 评论