Defined link styles for your page display properly in all browsers but appear red in Safari.
Check CSS files, linked or imported into your X/HTML document, for 404 errors (page not found). Safari will render the X/HTML 404 page as if it is a CSS document. Thus, if the 404 document has CSS styles defined in the head, it may override your defined link styles.
When checking your page in various browsers, you may find Safari displaying a bright red text color for your page anchors (links), overriding the colors you've specified in your CSS selectors.
First, look for a CSS document that may not be uploaded to your server. It will be returning a 404 (page not found) error. The simplest way to do this is to use the Web Developer's Toolbar extension for Firefox (by Chris Pederick) and simply click on the CSS > View CSS menu item. The page that appears will actually render the 404 error page code (if it exists) among the other linked and imported CSS documents. This method is effective because it pulls in any CSS documents related to your page -- even if they're brought in through a Javascript file.
Once you locate the document returning the 404 error, you can upload that CSS file to the server and your red links will disappear.
Theory is that Safari is erroneously rendering the 404 document (since it's being returned in place of a CSS file) as a CSS document. And thus, the red link selectors in the head of the error document are overriding your own selectors.
Note: This problem only exists on certain servers since 404 error documents will differ slightly. If you create a custom 404 page for your site, it's likely you'll never see this problem (or may see something entirely different).
Text ID: SAFARI_DISPLAYS_RED_LINKS
To add a comment, please Log in.
!important
by Gee(k) on April 16, 2009
This might be useful:
add the !important bit to the color and safari will read that instead of any other css (404 page)
ie
a { color: #fff !important; }
Thanks a lot. It helped me very much.
by paintmylife on January 12, 2009
En sisya araama.
Thanks
by l!ttleMatt on August 6, 2008
I was ready to give up on this problem but this really helped. Thank you!
Uploading CSS files to server?
by LisaandKay on August 4, 2008
So how do you upload the CSS files to the server?
Opera has this same problem
by Ashung on April 17, 2008
I found some version of Opera has this same problem.
I change the css as follows:
body a:link, body a:visited { color: #06c; text-decoration: none; }
body a:hover, body a:active { color: #09f; }
it can also solve this problem.
problem solved
by p.lopee on February 2, 2007
Thanks for the tip. With the Firefox developer toolbar, this was quite easy to do and solved the problem.