Toon posts:

[CSS] Probleem links in stylesheets

Pagina: 1
Acties:

Verwijderd

Topicstarter
In een site die ik maak gebruik ik stylesheets waarin verschillende classes zijn gedefinieerd. Dat werkt perfect, alleen als ik twee verschillende soorten links in een pagina wil hebben lukt dat niet. Ik heb bijvoorbeeld de classes "link1" en "link2" in het stylesheets staan, maar IE5 pakt alleen de laatste class of helemaal geen. Het lijkt er dus op dat ik maar 1 link-class voor een stylesheet kan maken, en dus ook voor mijn pagina (ik heb ook al geprobeerd de style direct in de pagina te zetten, maar dan wordt alleen deze style aangesproken en niet meer die van in het stylesheet).

Ik hoop dat iemand hier een goede oplossing voor weet, alvast bedankt daarvoor.

Verwijderd

laat je style sheet eens zien...

  • dusty
  • Registratie: Mei 2000
  • Laatst online: 21-02 00:06

dusty

Celebrate Life!

Geen code, geen oplossing.

Back In Black!
"Je moet haar alleen aan de ketting leggen" - MueR


  • rickmans
  • Registratie: Juli 2001
  • Niet online

rickmans

twittert

ik sluit me helemaal aan bij de vorige 2 graag code :), wel alles netjes neergezet?

Don't mind Rick


  • wicher|IA
  • Registratie: November 2000
  • Laatst online: 10-04-2023
Op vrijdag 21 september 2001 15:21 schreef GPM het volgende:
Het lijkt er dus op dat ik maar 1 link-class voor een stylesheet kan maken
nee hoor

maar idd: zonder code geen oplossing mogelijk

Verwijderd

Topicstarter
Hier een voorbeeldje van een stylesheet:

.Standaard {
A {text-decoration: none; font-weight: bold }
A:link {color: #00000}
A:visited {color: #00000}
A:hover {text-decoration: none; color: #FFFFFF;font-size: 10pt; }
A:active {text-decoration: none; color: #FFFFFF; font-size: 10pt;}
td{ font-family: Verdana; font-size: 10pt; font-style: normal; color: #000000 }
Body{ font-family: Verdana; font-size: 10pt; font-style: normal; color: #000000 }
INPUT{font-family: Verdana, Helv; font-size: 10px; color: #000000;}
}

.link
{ font-family: Verdana;
font-size: 10pt;
font-style: normal;
font-weight: bold;
cursor: hand;
color: #0000FF
a:link {font-style: bold; color: #0000FF;text-decoration: none; font-size: 10pt;}
a:visited {font-style: bold; color: #0000FF;text-decoration: none; font-size: 10pt}
a:active {font-style: bold; text-decoration: none; color: #0000FF; font-size: 10pt;}
a:hover {font-style: bold; text-decoration: none; color: #FF6E1F;font-size: 10pt;}
}

.linktwee
{ font-family: Verdana;
font-size: 10pt;
font-style: normal;
font-weight: bold;
cursor: hand;
color: #FF00FF
a:link {font-style: normal; color: #FF00FF;text-decoration: none; font-size: 8pt;}
a:visited {font-style: normal; color: #00FFFF;text-decoration: none; font-size: 8pt}
a:active {font-style: normal; text-decoration: none; color: #00FFFF; font-size: 8pt;}
a:hover {font-style: normal; text-decoration: none; color: #F1611F;font-size: 8pt;}
}



En hier een stukje van de pagina:

<html>
<head>
<title>Demonstratie</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" type="text/css" href="link1.css">
</head>
<body width="300px" leftmargin="0px" topmargin="0px" marginwidth="0px">
<table width="150" border="0" cellspacing="0" cellpadding="0" height="120">
<tr>
<td height="20" >
<div align="center"><a href="mainframe.htm" class="link">Demonstratie</a></div>
</td>
<td height="20" >
<div align="center"><a href="mainframe.htm" class="linktwee">Demonstratie</a></div>
</td>
</tr>
</table>
</body>
</html>


Het probleem is dus dat bij de eerste link de class "linktwee" wordt gebruikt en niet "link".

  • rickmans
  • Registratie: Juli 2001
  • Niet online

rickmans

twittert

doe het is goed >:)
kortom
a:link voor een gewone link en
a:link.class voor een speciale :)

Don't mind Rick

Pagina: 1