Editing the in the courses list on My Moodle page

Editing the in the courses list on My Moodle page

by Glenn Pillsbury -
Number of replies: 5

Hi,

I really need to tweak the display of the course link on the My Moodle page.  It's being displayed via an <h2> but I can't find where that html is generated.  I need to restyle that one <h2> differently from the rest of the h2's.  As far as I can tell, the DOM aspect of that particular h2 is not distinctive enough to use a stylesheet CSS declaration rather than hard-coding it.  If I'm wrong on that, please correct me!

In any case, does anyone know which file I need to look at?  It's not in my/index.php or course/lib.php.

Thanks,
Glenn

Average of ratings: -
In reply to Glenn Pillsbury

Re: Editing the in the courses list on My Moodle page

by Mary Evans -
Picture of Core developers Picture of Documentation writers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Glenn,

It all depends on which version of Moodle you are using. CSS FAQ is a good staring point to learn more about CSS in Moodle. Using FireBug add-on in FireFox is also very useful in identifying elements you want to style.

Whichever Moodle version you use you need to make changes to the CSS files for the theme you are presently using as your default theme.

Hope this helps?

Mary

In reply to Glenn Pillsbury

Re: Editing the in the courses list on My Moodle page

by John St -

With 1.9 or 2 you can just get the my moodle page's body ID and use that to single out the h2. In the case of 1.9x, you could do:

#my-index h2.main a {

some stuff here

}

In reply to John St

Re: Editing the in the courses list on My Moodle page

by Glenn Pillsbury -

Hi John,

Thanks for the tip.  Works great.

Glenn

In reply to Glenn Pillsbury

Re: Editing the in the courses list on My Moodle page

by Mary Evans -
Picture of Core developers Picture of Documentation writers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Glenn:

Further to my last comment above, you may find this forum discussion of interest:

http://moodle.org/mod/forum/discuss.php?d=157935

Mary

In reply to Mary Evans

Re: Editing the in the courses list on My Moodle page

by Glenn Pillsbury -

Thanks Mary.  The advanced selectors idea mentioned in that other thread would have been useful to pursue as well.