Is there a html code that exists that prevents the links on my website from being a) underlined and b) a different colour from my text?
Basically I want all the text to be the same colour and format, despite having active links.
What html can I use to stop my links from being underlined?
You could do this
put the following between your %26lt;head%26gt; tags
%26lt;style type="text/css"%26gt;
a { text-decoration: none; }
%26lt;/style%26gt;
OR
you could just do this
if you just want to do it on 1 or 2 links
%26lt;a href="link.htm" style="text-decoration:none"%26gt;
you would use option 1 if you wanted that for all links!
Joe
Reply:%26lt;a href="%26lt;URL%26gt;" style="text-decoration:none; color:black"%26gt;Link Text%26lt;/a%26gt;
Reply:Check these out.
http://www.permadi.com/tutorial/remLinks...
How to Set the Color for Links in a Web Page You Design
http://www.ehow.com/how_10009_set-color-...
Also, Tools, Internet Options, Color
Reply:If you manage all your different text styles with Cascading Style Sheets (you should), it's pretty easy. Create a link style that overrides the underlining that links default to, and sets the color the same as the other text. First the "body text" style, then the "link" style:
%26lt;style%26gt;
.bodyytext {
font-family:Arial;
font-size:11px;
color: black }
.link {
text-decoration:none }
%26lt;/style%26gt;
using regular text, set up a block like the following, and the link tag inside will inherit the bodytext attributes and override the underlining of links:
%26lt;p class="bodytext"%26gt;text here %26lt;a href="http://www.yahoo.com" class="link"%26gt;link here%26lt;/a%26gt; more text here%26lt;/p%26gt;
The %26lt;style%26gt;...%26lt;/style%26gt; chunk can go in the %26lt;head%26gt; section of the document. Or use a separate stylesheet.
Reply:%26lt;head%26gt;
%26lt;style type='text/css'%26gt;
a, a:visited
{ text-decoration:none;
color:#000000;
}
%26lt;/style%26gt;
%26lt;/head%26gt;
Put that at the top (or just in your CSS if you know where/what that is) and all your links will have no underline and you can replace the color with whatever you want. (#000000 is black).
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment