WCM Forum

WCM Forum (http://www.wcm.at/forum/index.php)
-   Programmierung (http://www.wcm.at/forum/forumdisplay.php?f=17)
-   -   Verschiedene Linkfarben (http://www.wcm.at/forum/showthread.php?t=99397)

blauesau 09.06.2003 10:03

Verschiedene Linkfarben
 
Ist es möglich mit CSS verschiedene Linkfarben zu realisieren?

Z.B.: ...

Und im CSS:

a.weiss { color:#FFFFFF }

So funktioniert es leider nicht...

blauesau 09.06.2003 10:13

Ach funktioniert eh, das "visited" hat mir einen Strich durch die Rechnung gemacht...

_m3 09.06.2003 10:18

Also Im Mozilla 1.4 und im IE 6.0 tut das folgende Script genau das, was Du willst:
PHP-Code:

<html>
<
head>
<
title>Color-test</title>
<
style type="text/css">
    
BODY background-color:red; }
    
a.weiss color:#FFFFFF } 
</style>
</
head>
<
body>

[
url="http://www.wcm.at/"]WCM[/url]

</
body>
</
html


sagi 09.06.2003 11:03

Zitat:

a.weiss { color:#FFFFFF }
Im Idealfall sollte am Ende noch ein Strichpunkt stehen:

a.weiss { color:#FFFFFF; }

;)

mfg

c.

SNo0py 11.06.2003 12:54

z.B.:

Code:

/* navigation-links */
.nav_link:link {  color: #FFFFFF; text-decoration: none; font-weight: normal}
.nav_link:visited {  color: #FFFFFF; text-decoration: none; font-weight: normal}
.nav_link:hover {  color: #CC0000; text-decoration: none; font-weight: normal}
.nav_link:active { color: #CC0000; text-decoration: none; font-weight: normal}
.nav_link_act:link {  color: #FFFFFF; text-decoration: none; font-weight: bold}
.nav_link_act:visited {  color: #FFFFFF; text-decoration: none; font-weight: bold}
.nav_link_act:hover {  color: #B8B870; text-decoration: none; font-weight: bold}
.nav_link_act:active { color: #B8B870; text-decoration: none; font-weight: bold}

/* links */
a:link {  color: #003399; text-decoration: underline; font-weight: bold}
a:visited {  color: #003399; text-decoration: underline; font-weight: bold}
a:hover {  color: #CC0000; text-decoration: underline overline; font-weight: bold}
a:active { color: #CC0000; text-decoration: underline overline; font-weight: bold}

Und dann
Code:

<a href="..." class="nav_link"...>
--> Achtung auf die Reihenfolge!

mfg


Alle Zeitangaben in WEZ +2. Es ist jetzt 20:52 Uhr.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
© 2009 FSL Verlag