In article
<11**********************@l12g2000cwl.googlegroups .com>,
"shapper" <md*****@gmail.comwrote:
Hello,
I want to redefine the way an <atag behaves.
I saw to approaches:
.myClass a { ... }
and
a.myClass { ... }
What is the difference?
Which one should I use and how to apply them?
In the first, there is an element that is classed, inside of
which are some links. This way of identifying the links you want
a certain style is often better because it saves having to class
a lot of links individually.
eg.
<ul class="landscapes">
<li><a href="" ...>Picture of my house from the side</a></li>
<li><a href="" ...>Picture of my eel from the side</a></li>
<li><a href="" ...>Picture of beach storming troops as seen
through the slit in my machine gun nest</a></li>
etc
</ul>
The other way is more suited to where there are either just very
few links to be styled or to where the links to be thus styled
are scattered in all sorts of diverse contexts. You target them
individually.
>
I also need to change the style of a:link and a:hover.
Can I use both approaches for this?
Yes.
--
dorayme