PHP
PHP

Reputation: 443

How to Remove Underline below text using CSS

Below is my code ,in which i used text-decoration:none ; but it now works ,still there is a blue line under it. http://jsfiddle.net/NW8Nw/1/

//CSS

.thumbnail:hover{z-index: 50;text-decoration: none;position:relative;}
.thumbnail span{  position: absolute;background:#000;padding: 5px;left: -1000px;
 border: 0px solid #ddd;visibility: hidden;color: #fff;width:388px;height:190px;text-  decoration: none;}
.thumbnail:hover span{ text-align:left;visibility: visible;top: 0;left: 110px;text-  decoration:none;
top:-120px;-webkit-box-shadow: 0 8px 6px -6px #aaa; -moz-box-shadow: 0 8px 6px -6px   #aaa;box-shadow: 0 8px 6px -6px #aaa;}
.hoverbold{    text-decoration:none;
font-family:verdana;font-size:11px;color:#B09F6E;text-shadow:0px 0px 1px #B09F6E;}​

//HTML

 <div  class="thumbnail" style="position:relative;">
        <a href="<?php echo SITE; ?>">
<img src=""  style="border:6px solid #ddd;" height="110" width="140">
<div style="position:absolute;border:0;left:120px;top:90px;">
<img src="http://url.com/play.png" border="0"/>
<span>
<div style="padding-left:20px;">
<b style=" text-decoration:none;">Simply beautiful.</b>
</div>
<div style="padding:20px 0px 0px 20px;">
<b CLASS="hoverbold">EDITOR REVIEW :</b>
</div>
</span>​

Upvotes: 0

Views: 7158

Answers (3)

SVS
SVS

Reputation: 4275

Thats your text-shadow which is creating problem

.hoverbold {
  text-decoration: none;
  font-family: verdana;
  font-size: 11px;
  color: #B09F6E;
  text-shadow: 0px 0px 1px #B09F6E; /* Remove This */
}

Upvotes: 2

Mike Brant
Mike Brant

Reputation: 71384

You did not close your a tag. Also, you would need to apply the text-decoration:none; to the a tag, as that is what is causing the underline.

Upvotes: 0

UpQuark
UpQuark

Reputation: 801

Links are separate from texts in CSS, so you have to specifically set links to text decoration: none.

For example:

A:link {text-decoration: none}
A:visited {text-decoration: none}
A:active {text-decoration: none}

Upvotes: 0

Related Questions