Css link style is not recognized

Posted on 2011-10-31
Medium Priority
Last Modified: 2012-05-12

Please have a look at http://www.egyediszoftverek.hu/ideig/KaloczyAblakCsere/indexD.html

In Chrome and in some FireFox version the left side menus are orange, but they should be black (they use different style).
Thank you
Question by:starhu
  • 2
  • 2
LVL 84

Expert Comment

by:Dave Baldwin
ID: 37059648
Firebug says that in line 644 of ablakcsere.css, you have the color declared as #FF4500.  Those links go to black on yellow on 'hover'.
LVL 22

Expert Comment

by:Kim Walker
ID: 37059649
The a:link style on line 644 of ablakcsere.css is setting links to orange.

Author Comment

ID: 37062284
Doesn't it matter that .szovegFOMENU is set to black and this is surrounding the links?

How can I override these links then.

I read that the following should work but at me it doesn't

#main_left_red a:hover {
color: #fff !important;
In html:
<div id="main_left_red">      
       <a href="mylocatin.cfm>">txt goes here</a>          
LVL 22

Accepted Solution

Kim Walker earned 2000 total points
ID: 37062316
a:link is getting priority because it is more specific. Try adding an even more specific selector to your .szovegFOMENU style.

.szovegFOMENU, .szvogFOMENU a:link {
    color: black;
    font-size: 14px;
    font-weight: bold;

Open in new window

LVL 84

Expert Comment

by:Dave Baldwin
ID: 37064793
What matters is the last style that is applied.  When you have more than one entry for an item, the order that they are applied is important because each one becomes the current style as it is encountered.  This a:link is near the end of the file so it becomes the last style applied to links.  Styles without classes or ids like this should usually be first in the CSS file so that more specific styles will over ride them.
a:link {
	color: #ff4500;
	text-decoration: none;
	background-color: transparent;

Open in new window


Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…
Suggested Courses

850 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