使用 CSS 设置右边框的颜色

cssweb developmentfront end technology更新于 2025/5/10 13:00:17

要设置右边框的颜色,请使用 border-right-color 属性。您可以尝试运行以下代码来实现 border-color 属性。 −

示例

<!DOCTYPE html>
<html>
   <head>
      <style>
         p {
            border-style: dotted;
            border-right-color: #FFFF00;
         }
      </style>
   </head>
   <body>
      <p>This is demo text.</p>
   </body>
</html>

输出


相关文章


有用资源