GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Python24/11JavaScript/day01/basic02.html at master · ItJava/Python24

Expand file tree

/

basic02.html

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
47 lines (38 loc) · 1.5 KB
/

basic02.html

Copy path

File metadata and controls

47 lines (38 loc) · 1.5 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
<script>
window.onload = function () {
function func1() {
var oBtn1 = document.getElementById("btn1")
var oBtn2 = document.getElementById("btn2")
var oBtn3 = document.getElementById("btn3")
// 这里的事件采用匿名函数,匿名函数主要用来执行命令的
oBtn1.onmouseenter = function () {
console.log("鼠标滑过...");
}
oBtn2.onclick = function () {
console.log("鼠标点击...");
}
oBtn3.onmouseleave = function () {
console.log("鼠标离开...");
}
// id也可以添加到head中的标签身上,
// 比如link的css外链式,通过id来设置css的href属性来实现加载不同的网页皮肤
// 如果标签有自己的类或者修改类名为类名2来切换css样式
}
func1();
}
</script>
</head>
<body>
<button id="btn1">鼠标滑过</button>
<button id="btn2">鼠标点击</button>
<button id="btn3">鼠标离开</button>
</body>
</html>
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.