Forum Moderators: not2easy

Message Too Old, No Replies

Remove Part of a Link Underline

         

Rain_Lover

4:17 pm on Jul 26, 2010 (gmt 0)

10+ Year Member Top Contributors Of The Month



Hi,

How can I remove the word Text underline using inline style?
<a href="http://www.example.com/">Some Text</a>


Thanks in advance!
Rain Lover

Major_Payne

5:04 pm on Jul 26, 2010 (gmt 0)



Might try:

<a style="text-decoration: none;" href="http://www.example.com/">Some Text</a>


Ron

topr8

5:16 pm on Jul 26, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



<a href="http://www.example.com/">Some <span style="text-decoration: none;">Text</span></a>

Rain_Lover

6:11 pm on Jul 26, 2010 (gmt 0)

10+ Year Member Top Contributors Of The Month



@ Major_Payne,

It removes all the linked words underline.

@ topr8,

Thanks for the answer, but it doesn't work.

Major_Payne

12:26 pm on Jul 27, 2010 (gmt 0)



OK. Mis-understood you then. I thought you wanted the underline removed for the text description for the link. I see you just want it for the ONE word in the text link which is an unusual way of doing it.

Why not just put the link tag around the one word you want as a link and eliminate the extra coding. This works in Firefox:

<style type="text/css">
a#special_link { text-decoration: none; }
span#special { text-decoration: underline; }
</style>


<p><a id="special_link" href="http://www.example.com/"><span id="special">Some</span> Text</a></p>

Rain_Lover

1:18 pm on Jul 27, 2010 (gmt 0)

10+ Year Member Top Contributors Of The Month



It works!
Thanks. :-)

Major_Payne

1:48 pm on Jul 27, 2010 (gmt 0)



You're welcome.

Ron