?? 3.44 textarea上翻下翻按鈕.htm
字號:
<html>
<head>
<title>表格顯示數據表記錄</title>
</head>
<body>
<textarea id=myTxt style="overflow:hidden" width="20" height="20">
測試數據
測試數據
測試數據
測試數據
阿斗司法司法
測試數據
測試數據
測試數據
測試數據
測試數據
測試數據如肺炎
</textarea>
<button onmouseup=stop() onmousedown=up()>上翻</button><button onmousedown=down() onmouseup=stop()>下翻</button>
<script>
var Timer=null;
function up()
{myTxt.doScroll("scrollBardown") //調用滾動條,實現上翻
Timer=setTimeout("up()",100)
}
function down()
{myTxt.doScroll("scrollBarUp") //調用滾動條,實現下翻
Timer=setTimeout("down()",100)
}
function stop()
{clearTimeout(Timer)} //清空定時器
</script>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -