css设置按钮边框颜色
时间: 2023-07-29 13:13:36 浏览: 238
可以使用 CSS 的 border 属性来设置按钮的边框颜色,例如:
```css
button {
border: 2px solid red;
}
```
这将会把按钮的边框设置为红色实线,边框宽度为 2px。你可以根据需要设置不同的边框样式和颜色值。如果你只想要设置边框颜色而不改变边框样式和宽度,可以使用 border-color 属性,例如:
```css
button {
border-color: green;
}
```
这将会把按钮的边框颜色设置为绿色。当然,你也可以根据需要设置其他样式属性来美化按钮。
阅读全文
相关推荐















