PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Graphisme & Infographie > macromedia.dreamweaver > CSS Pseudo Classes
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
CSS Pseudo Classes

Réponse
 
LinkBack Outils de la discussion
Vieux 10/04/2008, 19h49   #1
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut CSS Pseudo Classes

:confused;

Hello. I am hoping you can me with a problem that I have been struggling
with for the past couple of weeks. I am attempting to create a webpage using
Cascading Style Sheets and I need to create two sets of hyperlinks colors using
the Selectors for a:link, a:visited and a:hover.

Here is an example of the type of effect that I am trying to create:

http://www.plantation.org/web/residents.html - This page has a set of
hyperlinks are black, that switch to the color white on hover, and another set
of hyperlink colors that are blue.

Here are the two classes that I need to design:
First Class:

a:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: xx-small;
font-weight: bold;
color: #FFFFFF;
text-decoration: underline;
}
a:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: xx-small;
font-weight: bold;
color: #FFFFFF;
text-decoration: underline;
}
a:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: xx-small;
font-weight: bold;
color: #FFFF33;
text-decoration: underline;
}

Second Class:
a:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
font-weight: bold;
color: #FFFF33;
}
a:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
color: #FFFF33;
font-size: 10px;
}
a:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
font-weight: bold;
color: #FFFF33;
text-decoration: underline;
}

Can you explain how to do this using Dreamweaver? I know how to create two
seperate style sheets using CSS and attach them to a page but when I do one
sheet overrides the other. I haven't had much luck in locating any information
on the Internet and I confirmed with Customer Support over the phone that there
isn't any documentation either in the forum or the guide on how to do this.
Thanks in advance for your

  Réponse avec citation
Vieux 10/04/2008, 20h05   #2
John Waller
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

>> I need to create two sets of hyperlinks colors using the Selectors for
>> a:link, a:visited and a:hover.


http://www.projectseven.com/tutorial...sses/page3.htm

--
Regards

John Waller


  Réponse avec citation
Vieux 10/04/2008, 21h44   #3
Malcolm _
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

On Thu, 10 Apr 2008 18:49:37 +0000 (UTC), "slyboy69er"
<webforumsuser@macromedia.com> wrote:

>:confused;
>
> Hello. I am hoping you can me with a problem that I have been struggling
>with for the past couple of weeks. I am attempting to create a webpage using
>Cascading Style Sheets and I need to create two sets of hyperlinks colors using
>the Selectors for a:link, a:visited and a:hover.
>
> Here is an example of the type of effect that I am trying to create:



Why use two style sheets - just create two classes with different
pseudo selectors and select the one you need.

Also greatly simplified the css - you have a lot of redundant code.

is this what you mean ??


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
<title>Untitled Document</title>
<style type="text/css">

body {background-color:#999999;}

..link1 a { font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: xx-small;
font-weight: bold;
text-decoration: underline;
margin: 10px; }

..link1 a:link, .link1 a:visited { color: #FFFFFF; }
..link1 a:hover { color: #FFFF33; }

..link2 a { font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10px;
font-weight: bold;
margin: 20px; }


..link2 a:link { color: #FFFF33; }
..link2 a:visited { color: #FFFF33; }
..link2 a:hover { color: #FFFF33; text-decoration: underline; }
</style>
</head>

<body>

<div class="link1">
<h1>Links 1</h1>
<a href="#">one</a>
<a href="#">two</a>
<a href="#">three</a>
<a href="#">four</a></div>
<div class="link2">
<h1>Links 2</h1>
<a href="#">one</a>
<a href="#">two</a>
<a href="#">three</a>
<a href="#">four</a>
</div>
&nbsp;
</body>
</html>
--

~Malcolm~*...
~*
  Réponse avec citation
Vieux 11/04/2008, 19h30   #4
Malcolm _
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

On Thu, 10 Apr 2008 18:49:37 +0000 (UTC), "slyboy69er"
<webforumsuser@macromedia.com> wrote:

>:confused;
>
> Hello. I am hoping you can me with a problem that I have been struggling
>with for the past couple of weeks. I am attempting to create a webpage using
>Cascading Style Sheets and I need to create two sets of hyperlinks colors using
>the Selectors for a:link, a:visited and a:hover.
>


>
> Can you explain how to do this using Dreamweaver? I know how to create two
>seperate style sheets using CSS and attach them to a page but when I do one
>sheet overrides the other. I haven't had much luck in locating any information
>on the Internet and I confirmed with Customer Support over the phone that there
>isn't any documentation either in the forum or the guide on how to do this.
>Thanks in advance for your



Did that ???
--

~Malcolm~*...
~*
  Réponse avec citation
Vieux 11/04/2008, 20h00   #5
jhabrix
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

slyboy69er

If you need to create two sets, ideally, either name the divs, tables,
whatever and put the parameters in there:

#xxx a {
xxx
}

or create classes

.pinklink a {
xxxx
}

.bluelink a {
xxxx
}

If you want the background to change color on link, hover, etc. you need this
within the curly brackets:

{
background-color: #xxxxxx;
display: block;
}

Then the background color will change on the rollover (once you change the
colour under the a:hover attribute... etc., etc.

Cheers

JJ

  Réponse avec citation
Vieux 15/04/2008, 15h22   #6
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

Thank you for your John. The document that you provided solved my problem!


  Réponse avec citation
Vieux 15/04/2008, 15h24   #7
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

Thanks for your John. The document you provided solved my problem
  Réponse avec citation
Vieux 15/04/2008, 15h28   #8
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

Hello Malcolm. Thak you for taking the time to contact me with your suggestion.
Another member provided me with some documentation that ed answer my
question but I used your suggestion about creating a single style sheet. Best
wishes!

  Réponse avec citation
Vieux 15/04/2008, 15h29   #9
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

:grin; It did - thank you very much for your !
  Réponse avec citation
Vieux 15/04/2008, 15h31   #10
slyboy69er
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: CSS Pseudo Classes

:grin; Thanks for getting back to me. It worked! Best wishes.
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 02h44.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,12509 seconds with 18 queries