So... this is my problem:
I made a list of links using a php loop.
What I want to do next is to colour each and everyone of them, but with a different colour when hovered over by the mouse. (red and lime)
These colours will be stacked inside a .txt file (I already figured that part out).
I've already found a way to do so, but it was creating a new div every time the loop was done and doing such, there was that space between divs that I don't like.
a {
color:white;
-o-transition:color .3s ease-out;
-ms-transition:color .3s ease-out;
-moz-transition:color .3s ease-out;
-webkit-transition:color .3s ease-out;
transition:color .3s ease-out;
text-decoration: none;
}
a:hover { color:cyan; }
This is my css code for the normal hover (in case there is neither red nor lime for that link)
I'm trying to tell the "code" which colour to apply by using php variables (already figured that part too).
My question is: Is it possible to have, let's say, "subclasses" to a class? I mean, to be able to make a "subclass" for the lime and one for the red, having all in ONE div and applying them by php variables.
SOLVED! Thank you all very much for your help and sorry that I couldn't be more exact when writing this.