Skip to main content
Question

CSS for Video on Course Landing Pages


katherinewarren
Novice II

Does anyone have experience using CSS to embed a video on the course landing pages (before login)? I’d like to add videos to the course landing pages that showcase the course’s purpose to the public to encourage learners to enroll in a course.

5 replies

lrnlab
Hero III
Forum|alt.badge.img+8
  • Hero III
  • 4788 replies
  • March 14, 2025

Are you saying you want to add a video the course description?

You can do that by storing your video on a player like Vimeo or YouTube and using the icon (see below) to link to it.

 


elamast
Hero I
Forum|alt.badge.img+5
  • Hero I
  • 245 replies
  • March 14, 2025

The easiest way is to add preview material to a course under Properties → Catalog Options → Demo Material (up to 4 MB).  It will end up looking like this:

 

The benefit to this approach is that it is course-specific.

You could conceivably use CSS to change the background of an element (like the blue header above) to a video, but it would apply to every course page with that element.  To do that convert your video to an animated gif and use this CSS (changing out the gif for one of your own):

dcb-te-content-overview-header .dcb-te-content-overview-header-wrapper.dcb-te-content-overview-header-with-background-image, dcb-te-content-overview-header .dcb-te-content-overview-header-wrapper.dcb-te-content-overview-header-with-background-color {

background-image: url("https://media1.tenor.com/m/MWz8PRVJtywAAAAC/regret-evator.gif") !important;

}

 

If you need a page-specific video which can appear anywhere you want, then you’d need to resort to JavaScript, which is not supported by Docebo.

 


lrnlab
Hero III
Forum|alt.badge.img+8
  • Hero III
  • 4788 replies
  • March 14, 2025

@elamast I get what you're saying but 4MB for a video could be way too small a file size.


elamast
Hero I
Forum|alt.badge.img+5
  • Hero I
  • 245 replies
  • March 14, 2025
lrnlab wrote:

@elamast I get what you're saying but 4MB for a video could be way too small a file size.

 

Agreed.  For that we should probably open up a feature request to change the size limit.

The only other way I can think of is to use JavaScript, which I probably can’t give details on in this forum.


katherinewarren
Novice II

Thanks everyone. I looked at the demo material option but 4mb is too small for a video file. Sounds like there still is not a feasible option for this.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings