Reputation: 615
My HTML code is:
<a href="settings.html">settings</a>
The element does not lies directly under the body tag. Now i have a situation where i need To underline anchor tag text using CSS, to do it i am using the following css code:
a{ border-bottom: solid 1px #eee;}
However this only underlines the text enclosed in anchor tag. What if want the underline to go across the page?
Upvotes: 0
Views: 2832
Reputation: 13211
This is what you might want to do:
a {
border-bottom: solid 1px red;
display: block;
}
<a href="settings.html">settings</a>
Upvotes: 4