Active lable in custom menu

Active lable in custom menu

par jaffer mirza,
Nombre de réponses : 3

hello,

I am using moodle 2.3.1 and want to know how to customize the custom menu so that it changes the colour when that particular link is active?

Moyenne des évaluations  -
En réponse à jaffer mirza

Re: Active lable in custom menu

par Mary Evans,
Avatar Core developers Avatar Documentation writers Avatar Peer reviewers Avatar Plugin developers Avatar Testers

#custommenu ul li:active,
#custommenu ul ul li:active,
#custommenu ul ul ul li:active {background-color: red; color: white;}

En réponse à Mary Evans

Re: Active lable in custom menu

par Prakash Pa,
Hi,


I added menu items in admin. Now menu is showing up. But the current item is not shown as active. I managed to fix it by writing my own code. But if I select the child category, the parent is not highlighting. Please help. Does the moodle menu supposed to do this automatically?

Thanks,

Prakash Pa

En réponse à Prakash Pa

Re: Active lable in custom menu

par Mary Evans,
Avatar Core developers Avatar Documentation writers Avatar Peer reviewers Avatar Plugin developers Avatar Testers

Well we are not magicians and don't read minds, so we cannot help you, as you did not give us the version of Moodle that you are using. Nor did you say which theme as there are two sets of menu code in Moodle since version 2.5.

Also this old discussion relates to Moodle 2.3, but I doubt you are using that version -or are you? If you are,  then just copy the CSS I added in my last comment.

Thanks,

Mary