Computer >> कंप्यूटर ट्यूटोरियल >  >> प्रोग्रामिंग >> CSS

CSS के साथ पिल बटन कैसे बनाएं?

<घंटा/>

पिल बटन बनाने के लिए कोड निम्नलिखित है -

उदाहरण

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style>
button {
   font-family: "Lucida Sans", "Lucida Sans Regular", "Lucida Grande",
"Lucida Sans Unicode", Geneva, Verdana, sans-serif;
   background-color: rgb(193, 255, 236);
   border: none;
   color: rgb(0, 0, 0);
   padding: 10px 20px;
   text-align: center;
   text-decoration: none;
   display: inline-block;
   margin: 4px 2px;
   cursor: pointer;
   font-size: 30px;
   border-radius: 32px;
}
button:hover {
   background-color: #9affe1;
}
</style>
</head>
<body>
<h1>Pill Buttons Example</h1>
<button>Button 1</button>
<button>Button 2</button>
<div></div>
<button>Button 3</button>
<button>Button 4</button>
</body>
</html>

आउटपुट

उपरोक्त कोड निम्न आउटपुट उत्पन्न करेगा -

CSS के साथ पिल बटन कैसे बनाएं?


  1. CSS के साथ कार्ड कैसे बनाएं? CSS के साथ कार्ड कैसे बनाएं?

    CSS के साथ कार्ड बनाने के लिए, कोड इस प्रकार है - उदाहरण body{ font-family:Segoe UI , ताहोमा, जिनेवा, वर्दाना, सेन्स-सेरिफ़; मार्जिन:20 पीएक्स; } .कार्ड { बॉक्स-छाया:0 4px 8px 0 rgba(0,0,0,0.2); चौड़ाई:40%; अधिकतम-चौड़ाई:300px; पृष्ठभूमि-रंग:आरजीबी (56, 185, 185); } .कार्ड:होवर {बॉक्स-छाया:0 8px 16

  1. CSS के साथ कूपन कैसे बनाएं? CSS के साथ कूपन कैसे बनाएं?

    CSS के साथ एक कूपन बनाने के लिए, कोड इस प्रकार है - उदाहरण <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1" /> <style>    body {       font-family: "Segoe UI", Tahoma

  1. सीएसएस के साथ तीर कैसे बनाएं? सीएसएस के साथ तीर कैसे बनाएं?

    सीएसएस के साथ तीर बनाने के लिए, कोड इस प्रकार है - उदाहरण <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1" /> <style>    body {       font-family: "Segoe UI", Tahoma,