Solved

CSS Style Sheet <a> Links

Posted on 2011-03-25
3
260 Views
Last Modified: 2012-05-11
I am trying to apply the below to my style sheet but it creates a green underline which when hovered over displays the following

Validation (css2.1): 'a' is not a know CSS property name

.Links
{
a:link { text-decoration: underline, font-size: 1em; }
a:hover { text-decoration: none; font-size: 2em; }
}
0
Comment
Question by:LBGUC04
3 Comments
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 167 total points
ID: 35214722
it should be

a.Links:link
{
text-decoration: underline, font-size: 1em;
}
a.Links:hover
{
text-decoration: none; font-size: 2em;
}
0
 
LVL 6

Assisted Solution

by:kswathi
kswathi earned 166 total points
ID: 35214752
.a { text-decoration: underline, font-size: 1em;}
.a:hover{text-decoration: none; font-size: 2em; }
or
.Links{text-decoration: underline, font-size: 1em;}

.Links:hover{ text-decoration: none; font-size: 2em; }
 Try the above
0
 
LVL 16

Assisted Solution

by:HagayMandel
HagayMandel earned 167 total points
ID: 35215015
The a and a:link will perform the same behavior.
I guess you are trying to style the links INSIDE your 'Links' div,  that has the class 'Links attached to.
<div class="Links"><a href="#">link</a></div>

Open in new window


in this case, this is the CSS:
.Links a:link {
	font-size: 1em;
	text-decoration: underline;
}
.Links a:hover {
	font-size: 2em;
	text-decoration: underline;
}

Open in new window


0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Refresh div via ajax without lost ccs <li> styles 8 33
Only three borders showing on image 5 19
Changing Two Areas of a Page 5 16
If condition on Html with Asp 11 15
So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question