x
1
2
<html>
3
<head>
4
<meta charset="utf-8">
5
<title>蜜蜂教程(mifengjc.com)</title>
6
<style type="text/css">
7
#ex1 {
8
border: 1px solid #FF0000;
9
}
10
</style>
11
<script>
12
function displayResult() {
13
document.getElementById("ex1").style.borderWidth = "thick thin";
14
}
15
</script>
16
</head>
17
<body>
18
19
<div id="ex1">这是一些文本</div>
20
<br>
21
<button type="button" onclick="displayResult()">修改四个边框的宽度</button>
22
23
</body>
24
</html>