Editing the Home page

Editing the Home page

by Léo PETIT -
Number of replies: 5
Hello everyone, i've been working on a moodle site for some time now. It is a IOMAD version because I have to manage multi-tenants.
I'm on a Boost-child theme (IOMAD) on Moodle version 4.2.4

However I need some help to edit the Home page, I tried to find which file I would have to edit without any success. My problem is that I want to edit the page header so that instead of displaying the "Full site name" it would look for something else and display it so that it looks different based on who is logged in. All the other contents are fine, I just miss this edit to make it wonderful.

Would you have any idea/tips on where to look at ?

Thanks a lot
Average of ratings: -
In reply to Léo PETIT

Re: Editing the Home page

by Bob Gilmore -
Picture of Particularly helpful Moodlers
I don't use IOMAD, but if you're able to edit the custom CSS for the theme your sites you can remove the standard site home header with

#page-site-index  #page-header {  display: none; }
You could then use the filtercodes plugin https://moodle.org/plugins/filter_filtercodes to create a custom intro, e.g. Welcome Bob Gilmore. with <h1>Welcome {fullname}.</h1> for example.

You can do a lot with the site home just using Custom CSS and then the site summary and some text-area elements to add in content.




In reply to Bob Gilmore

Re: Editing the Home page

by Léo PETIT -
It was that simple..
Thank you Bob, you lead me on the right track with the correct CSS. 

I renamed the full site name and short name as Academy so I have a "default" name which is showing here and there to avoid confusion. 
And then since on IOMAD each tenant has it's own Custom CSS (build after the theme Custom CSS) i've added this (I don't know if it's the best way but it works) : 

#page-site-index  #page-header { visibility: hidden; }
#page-site-index  #page-header:after { content:"CompanyName Academy"; visibility:visible; display:block; font-weight: 700; font-size: 1.875rem; margin-top: -50px;}

In reply to Léo PETIT

Re: Editing the Home page

by Bob Gilmore -
Picture of Particularly helpful Moodlers
Glad I could help. With just boost, bootstrap elements built into the theme and some custom CSS my currently 4.3 prototype looks like this. Still got some work to do, but it's very customisable.


In reply to Bob Gilmore

Re: Editing the Home page

by Léo PETIT -
It does look good, even though the fact that the 3 cards at the bottom are not equally wide as the banner haha
In reply to Léo PETIT

Re: Editing the Home page

by Bob Gilmore -
Picture of Particularly helpful Moodlers
Yeah, the cards are fixed width using flex boxes to fit into rows while the banner scales with screen width. So the width difference is intentional.