Adding a background image to the course title on the course page

Adding a background image to the course title on the course page

by Kevin Westbrook -
Number of replies: 2

Over the last year or so I must have spent days trying to find the answer to this. I have a situation where I want to deliver a course that could be for a group of unlinked individuals, but could also be for people from a single organisation. I want to be able to use different copies of the course for each situation. For the unlinked people, I would have my branding all over it, and for the other I would make it clear that it is for their organisation.

My approach would be, if it is possible, to have a standard background to the course name area ("Pre-sessional B2+ ... in the screenshot) and the organisational branding as an image in the "General" section (blue image in the screenshot). As you can see, I can do the latter, but I can find no way to do the former.

Just installed Moodle version 3.10, but I have been trying with 3.8 and 3.9. I am using the Boost theme, updated today, but I am not wedded to it. It is not a live platform - I am running it on my PC at the moment.

Any pointers gratefully received.

Attachment Screenshot - 17_11_2020 , 15_59_20.jpg
Average of ratings: -
In reply to Kevin Westbrook

Re: Adding a background image to the course title on the course page

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers
Is there anything unique in the body classes if you have the course once and instead of your solution, turn on 'cohorts' / 'groups' and have a 'cohort' / 'group' for each of your groups of people? If so then you'd have a means of having targeted CSS backgrounds.
In reply to Gareth J Barnard

Re: Adding a background image to the course title on the course page

by Kevin Westbrook -
Thanks for the reply. I will need to put a bit more thought into it, but I don't think cohorts and groups work, although it would be nice if it did. These courses could be running widely separated in time. Also, I am not sure I would want the risk that I could end up communicating with everybody with information that could be confidential to the company concerned by not selecting the correct group when I send a message or set up an activity. I think it would also add a large amount of admin overhead as against having individual courses. Ideally, I want a standard course that I can clone for each customer, change the top image and I am ready to go.
Obviously, it would be much easier to just change the image in the General section of the course, and I will do that if the way I want to do is too complex, but I would guess that there is something somewhere that can be changed. I just don't know what and maybe it isn't that easy! I have no experience in creating themes.