HTML DOM borderBottom ÊôÐÔ

HTML DOM Style ¶ÔÏó

¶¨ÒåºÍÓ÷¨

borderBottom ÊôÐÔÔÚÒ»¸öÉùÃ÷ÖÐΪϱ߿òÉèÖÃËùÓеÄÊôÐÔ¡£

Óï·¨£º

Object.style.borderBottom=borderWidth borderStyle borderColor
Öµ ÃèÊö Öµ
borderWidth ÉèÖñ߿òµÄ¿í¶È¡£
  • thin
  • medium
  • thick
  • length
borderStyle ÉèÖñ߿òµÄÑùʽ¡£
  • none
  • hidden
  • dotted
  • dashed
  • solid
  • double
  • groove
  • ridge
  • inset
  • outset
borderColor ÉèÖñ߿òµÄÑÕÉ«¡£
  • color-name
  • color-rgb
  • color-hex
  • transparent

ʵÀý

ÏÂÃæµÄÀý×ÓÉèÖÃϱ߿ò£º

<html>
<head>
<style type="text/css">
p {border: thin dotted #FF0000}
</style>
<script type="text/javascript">
function changeBorder()
{
document.getElementById("p1").style.borderBottom="thick solid blue";
}
</script>
</head>
<body>

<input type="button" onclick="changeBorder()"
value="Change bottom paragraph border" />
<p id="p1">This is a paragraph with a border</p>

</body>
</html>

HTML DOM Style ¶ÔÏó

VUE