Link Colors In Hindi | Mayank Salvi
HTML Links - Different Colors
एक HTML
लिंक different color में display
होता है,
जो इस पर निर्भर करता है कि वह visited
है, unvisited
है,
या active
है।
HTML Link Colors
By default, सभी ब्राउज़रों में links निम्नानुसार दिखाई देंगे:
- एक unvisited लिंक underlined और नीला है
- Visit किया गया लिंक underlined और बैंगनी है
- एक active लिंक underlined और लाल है
आप CSS
का उपयोग करके लिंक की स्थिति का color
बदल सकते हैं:
Example
यहां, एक unvisited link बिना underline के green होगा। एक visit किया गया link pink होगा जिसमें कोई underline नहीं होगा। एक active link yellow और underlined होगा। इसके अलावा, जब किसी link (a:hover) पर माउस रखा जाता है तो वह red और underlined हो जाएगा:
<style>
a:link {
color: green;
background-color: transparent;
text-decoration: none;
}
a:visited {
color: pink;
background-color: transparent;
text-decoration: none;
}
a:hover {
color: red;
background-color: transparent;
text-decoration: underline;
}
a:active {
color: yellow;
background-color: transparent;
text-decoration: underline;
}
</style>
Link Buttons
CSS
का उपयोग करके एक link को एक button
के रूप में भी style
किया जा सकता है:
Example
<style>
a:link, a:visited {
background-color: #f44336;
color: white;
padding: 15px 25px;
text-align: center;
text-decoration: none;
display: inline-block;
}
a:hover, a:active {
background-color: red;
}
</style>
HTML Link Tags
Tag | Description |
---|---|
<a> | Defines a hyperlink |
Also Read:
Complete HTML Series In Hindi: Click Here