HTML Tutorial


 Forum HomeForum Home   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
Remove a link when it is made
Post new topic   Reply to topic    HTML Help Forum Index -> General HTML
View previous topic :: View next topic  
Author Message
veasna



Joined: 15 May 2007
Posts: 56

PostPosted: Mon Mar 10, 2008 4:44 pm     Remove a link when it is made Reply with quote

Dear,

When I create a new link to any text, it always goes
blue with underline. What I want is, I want that text
only to be blue but with no underline. Otherwise,
It is blue when I don't give it a move on it, but
it will turn into red when I move a mouse on it.

What is the code about this?

Thanks
sticks464



Joined: 31 Dec 2006
Posts: 1169

PostPosted: Mon Mar 10, 2008 6:01 pm     Reply with quote

By default browsers display links as blue and underlined. The way to remove the underline and set colors is
Example:
Code:
<style type="text/css">
a:link {
color: blue;
text-decoration: none;
}
a:hover{
color: red;
}
</style>
veasna



Joined: 15 May 2007
Posts: 56

PostPosted: Mon Mar 10, 2008 8:10 pm     Reply with quote

thanks. it works.

but can u tell me more how to refresh localhost?

it still has the old color-pink, not blue.

And it normally turn to red when I move on it
sticks464



Joined: 31 Dec 2006
Posts: 1169

PostPosted: Mon Mar 10, 2008 9:18 pm     Reply with quote

You shouldn't have to refresh localhost unless you leave your browser open. Then you need to refresh each time you want to view a change in your page. Are you using a:active and/or a:visited and IE? IE does not interpret one or the other of these (can't remember which one right now) and tries to display the a:link as one of them. If you have either of them in your styles, delete them, save your page and refresh your browser in localhost.
Corey Bryant
Site Admin


Joined: 15 May 2004
Posts: 8312
Location: Castle Pines North, CO USA

PostPosted: Tue Mar 11, 2008 12:50 pm     Reply with quote



The link is visited at that point and you need to apply styles to that as well (CSS Pseudo-classes)
Code:
a:link {color: #FF0000}     /* unvisited link */
a:visited {color: #00FF00}  /* visited link */
a:hover {color: #FF00FF}   /* mouse over link */
a:active {color: #0000FF}   /* selected link */

_________________
Corey
Hosting Solutions | Mile High Merchant Accounts | Expression Web Blog
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum Index -> General HTML All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
HTML Help topic RSS feed 

 
HOSTING / DESIGN
MAKE MONEY

Home
  |   Tutorials   |   Forum   |   Quick List   |   Link Directory   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial