首 页
网络学院
视频教程
资源下载
HOT
实例教程
图文教程
专题中心
学习社区
繁體中文
当前位置:
首页
>
图文教程
>
网络编程
>
Javascript
> Javascript模拟scroll滚动效果脚本
Javascript
[IE&FireFox兼容]JS对select操作
JS实现全景图效果360度旋转
Unicode 编码转换器
如何用javascript判断录入的日期是否合法
图片从右至左滚动JS
JS控件autocomplete 0.11演示及下载 1月5日已更新
一个对于js this关键字的问题
Javascript标准DOM Range操作全集
兼容Mozilla必须知道的知识。
你所要知道JS(DHTML)中的一些技巧
JS效率个人经验谈(8-15更新),加入range技巧
如何让动态插入的javascript脚本代码跑起来。
Javascript调试工具(下载)
脚本中出现 window.open() access is denied - 拒绝访问 情况一则及分析
Javascript-Mozilla和IE中的一个函数直接量的问题
贴一个在Mozilla中常用的Javascript代码
Javascript miscellanea -display data real time, using window.status
js技巧--转义符"\"的妙用
In Javascript Class, how to call the prototype method.(three method)
Javascript与vbscript数据共享
No.
«
‹
40
41
42
43
›
»
技术文章搜索
关键字
Javascript模拟scroll滚动效果脚本
出处:
互联网
整理:
软晨网(RuanChen.com)
发布:
2009-09-12
浏览: 233 ::
收藏到网摘: n/a
js点击出现场层层外点击层消失的代码
javascript各种复制代码收集
项目需要写了一段模拟Scroll滚动代码,分享的同时,我有些疑问,希望大家能帮忙解决,代码如下
点击运行可以看到效果:
Insert title here
1something
2something
3something
4something
5something
6something
7something
8something
9something
10something
11something
12something
13something
14something
15something
16something
17something
18something
19something
20something
21something
22something
23something
24something
25something
26something
27something
28something
29something
30something
上
1、键盘事件应加给window统一调配,根据category_hand激发状态判别处理。
2、放进function里,等页面加载完了再执行。
1、“键盘事件应加给window统一调配,根据category_hand激发状态判别处理”就是实现你这句话的策略:
“当点中滚动条后,触发键盘的上下键,来控制上下滚动”
category_hand被click时,将某个变量设为1,表示它被激活了。当网页内再发生鼠标按键事件时,解除激活。
某函数响应window对象的键盘事件,如果键盘事件发生时category_hand处于激活状态则执行相关代码。
2、获取页面元素对象,现在大家一般都用$()函数:
复制代码
代码如下:
function $(id) {
return document.getElementById(id);
}
js点击出现场层层外点击层消失的代码
javascript各种复制代码收集
评论 (0)
All
登陆
还没注册?