How can you insert a hyperlink in your site that does not include an underlined text? This is for a basic reason that most of the text of a hyperlink is underlined. How can I get rid of it?

Recommended Answers

All 3 Replies

You can do that using css.

<html>
<body>
<a href="http://www.example.com" style="text-decoration: none;">click here</a>
</body>
</html>

To apply the same style to all hyperlinks, use this.

<html>
<head>
<style type="text/css">
a {
text-decoration: none; 
}
</style>
</head>
<body>
<a href="http://www.example.com">Click here</a>
</body>
</html>

This will take off the underline from all a href links.

if you want to apply it to <asp:hyperlink web control then there is a ready attribute for you called font-underline , set it to false ;
<asp:hyperlink font-underline="false" ... >

Thanks! Its working...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.