The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

CSS: a:active not working?

View previous topic View next topic Go down

Solved CSS: a:active not working?

Post by Hert on July 14th 2015, 12:26 am

Hello,

I've been trying several things to make it work, but for some reason the a:active code does not work?
I have no default settings for it, neither for normal links but they do seem to work.
I've also tried: .gen a:active - but sadly that also doesn't seem to work.
I'm mainly focussing on the inbox right now, I haven't made any changes to the template.

Hopefully someone can help me with this problem!

Greetings,
Hert


Last edited by Hert on July 14th 2015, 11:47 pm; edited 1 time in total

Hert
Forumember

Posts : 81
Reputation : 3
Language : Dutch and English

http://afterthefall.actieforum.com/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by SLGray on July 14th 2015, 3:49 am

What are you trying to do?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35641
Reputation : 2374
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by Ange Tuteur on July 14th 2015, 7:21 am

Hi @Hert,

Have you setup your anchor rules like so ?
Code:
a:link {
  color:#39C;
}

a:visited {
  color:#99C
}

a:hover {
  color:#17A;
}

a:active {
  color:#333;
}

Your active rule should always be after :link, :visited, and :hover. Otherwise the :hover rule can override the :active rule. If it's still not taking effect, I'd recommend adding the !important flag to the properties in your :active rule. For example :
Code:
a:active {
  color:#333 !important;
}

Ange Tuteur
Forumaster

Male Posts : 13021
Reputation : 2683
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: CSS: a:active not working?

Post by Hert on July 14th 2015, 11:42 am

Hello @Ange Tuteur, thank you for wanting to help me with this (:

I did forget to place the rules in the correct order, but even after I did it still didn't work. I've also tried adding the !important flag - but it's still getting ignored.
Right now these are my CSS codes:
Code:
a:link {
color: #e57757; font: 10px 'Oswald';
text-transform: uppercase;
text-decoration: none!important;
}

a:visited {
color: #e57757; font: 10px 'Oswald';
text-decoration: none !important;
text-transform:uppercase;
}

a:hover{
color: #e57757; font: 10px 'Oswald';
text-decoration: none !important;
text-transform:uppercase;
}

a:active {
font: 10px 'Oswald' !important;
text-transform: uppercase !important;
color: #000000 !important;
}
Maybe I still did something wrong and I'm not seeing it?
(I will also skim through the rest of my CSS codes, but it's a looong list, to see if there could be a possible error somewhere else).



EDIT: I searched around and came to the conclusion that, for some reason, the links inbox, sentbox, outbox, savebox are not registered as active links when you are on one of these certain pages. I do not understand how or why, but I edited it in the HTML and it does work now.
I think that solves it, eventhough I would like to know WHY it is this way.

Hert
Forumember

Posts : 81
Reputation : 3
Language : Dutch and English

http://afterthefall.actieforum.com/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by Ange Tuteur on July 14th 2015, 6:28 pm

Yep that's all good. Wink

I'm only speculating, but if the anchor has a child element which defines a color, then you'll need to access this child element with CSS to change the color because it will override the parent's rule.

Something similar to this for example :
Code:
<a href="#"><span style="color:red">text</span></a>

and something like that to override it through a sheet.
Code:
a:active > span { color:blue !important }

Although I'm not entirely sure if that was the cause in your case. blackeye

Ange Tuteur
Forumaster

Male Posts : 13021
Reputation : 2683
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: CSS: a:active not working?

Post by SLGray on July 14th 2015, 7:50 pm

Try adding the CSS codes to the top of the stylesheet.


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35641
Reputation : 2374
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by Hert on July 14th 2015, 8:42 pm

@Ange Tuteur: Well you would think it's that, but that does not explain why the other CSS codes DID work on it - because then they should've been overrided aswell, don't you think?

@SLGray: Thank you, but I've already kind off fixed it (;

Hert
Forumember

Posts : 81
Reputation : 3
Language : Dutch and English

http://afterthefall.actieforum.com/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by APE on July 14th 2015, 11:41 pm

so is your problem now solved ? if yes please click on the solved button at the top of your first post so the staff know to lock it for you.

APE





APE
Manager
Manager

Male Posts : 8319
Reputation : 716
Language : fluent in dork / mumbojumbo & English haha
Location : STUCK IN FORUMOTIONS SERVERS HELP ME !!!!!!

http://chatworld.forumotion.co.uk/

Back to top Go down

Solved Re: CSS: a:active not working?

Post by SLGray on July 15th 2015, 1:52 am

Topic solved and archived


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35641
Reputation : 2374
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum