HTML DOM borderBottomWidth 属性

HTML DOM Style 对象参考手册

定义和用法

borderBottomWidth 属性设置下边框的宽度。

语法:

Object.style.borderBottomWidth=thin|medium|thick|length
值描述
thin定义细的下边框。
medium默认。定义中等的下边框。
thick定义粗的下边框。
length允许您自定义下边框的宽度。

实例

本例改变下边框的宽度:

<html>
<head>
<style type="text/css">
p
{
border: thin solid #FF0000
}
</style>
<script type="text/javascript">
function changeBorderWidth()
{
document.getElementById("p1").style.borderBottomWidth="thick";}
</script>
</head>
<body>
<input type="button" onclick="changeBorderWidth()"
value="Change bottom border" />
<p id="p1">This is a paragraph</p>
</body>
</html>

HTML DOM Style 对象参考手册