Computer >> คอมพิวเตอร์ >  >> การเขียนโปรแกรม >> CSS

จะเพิ่มเส้นขอบสีให้กับปุ่มด้วย CSS ได้อย่างไร?


หากต้องการเพิ่มเส้นขอบสี ให้ใช้คุณสมบัติเส้นขอบ CSS

ตัวอย่าง

คุณสามารถลองเรียกใช้โค้ดต่อไปนี้เพื่อเพิ่มเส้นขอบสี

<!DOCTYPE html>
<html>
   <head>
      <style>
         .button {
            background-color: yellow;
            color: black;
            text-align: center;
            font-size: 15px;
            padding: 20px;
            border-radius: 15px;
            border: 3px dashed blue;
         }
      </style>
   </head>
   <body>
      <h2>Result</h2>
      <p>Click below for result:</p>
      <button class = "button">Result</button>
   </body>
</html>