Fordson Theme - Embed responsive Videos by Vimeo

Fordson Theme - Embed responsive Videos by Vimeo

by Marcus Garvey -
Number of replies: 7

Hello,

I am running Moodle 3.2 with the 1.4 version of the wonderful Fordson theme. 

However, when I try to embed a video from Vimeo, its not displayed correctly and adjusted for mobile/tablet views. (I created pages, with texts and the embedded videos.)

Little research online suggests to add a little site-global CSS to the page

.responsive-video {
position: relative;
padding-bottom: 56.25%; /* Default for 1600x900 videos 16:9 ratio*/
padding-top: 0px;
height: 0;
overflow: hidden;
}

.responsive-video iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
and a div-wrapper around each iframe:

<div class="responsive-video">
<iframe src="http://player.vimeo.com/video/47387431?title=0&amp
;byline=0&amp;portrait=0&amp;autoplay=0"
width="1600" height="900" frameborder="0" webkitAllowFullScreen
mozallowfullscreen allowFullScreen></iframe>
</div>

Unfortunately its not working as intended and I see no adjustment at all, but maybe I paste the code into the wrong boxes. (Im an absolute css/moodle-beginner.) I tried to paste the code in the SCSS box of the color tab in Fordson, since its the only visible possibility for me to add CSS code (after I converted the CSS to SCSS online).

The display errors I receive upon that indicate that I might be totally wrong. Anybody got an idea or tip for me, how I can fix this issue for mobile users under Fordson?

Thanks in advance!


Average of ratings: -
In reply to Marcus Garvey

Re: Fordson Theme - Embed responsive Videos by Vimeo

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

Have you read the Moodle Doc about adding Videos to your courses?

This part of the document tells you how to add such a video. However reading the whole document you will learn a lot more, like enabling Filters etc.,

https://docs.moodle.org/31/en/Video#Using_the_Moodle_media_icon

Average of ratings: Useful (1)
In reply to Mary Evans

Re: Fordson Theme - Embed responsive Videos by Vimeo

by Marcus Garvey -

Hi Mary, 

thank you very much for your reply. 

Yes, I already took a look at the Doc and used it to my best knowledge. 

Unfortunately it didn't help. To create a better understanding where/how im stuck, I've added a screenshot of the issue.

Moodle Fordson embed Vimeo Videos responsive?

In reply to Marcus Garvey

Re: Fordson Theme - Embed responsive Videos by Vimeo

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

Did you clear caches after adding your css?

Average of ratings: Useful (1)
In reply to Marcus Garvey

Re: Fordson Theme - Embed responsive Videos by Vimeo

by Chris Kenniburg -
Picture of Particularly helpful Moodlers Picture of Plugin developers

Marcus,

I just tested your code and it works just fine on my site.  I took

.responsive-video {
position: relative;
padding-bottom: 56.25%; /* Default for 1600x900 videos 16:9 ratio*/
padding-top: 0px;
height: 0;
overflow: hidden;
}

.responsive-video iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
And put these into the RAW SCSS text box at the very bottom of the page of Fordson > Colours.

Save your changes.  The video correctly resizes in my testing.


To see an example, go to http://moodlesandbox.dearbornschools.org

Login as guest and on the homepage enter enrollment code-

4h3vij

It will take you to my test course and you can also demo the efficiency of our cool new Easy Enrollment plugin for Fordson!

Average of ratings: Useful (1)
In reply to Chris Kenniburg

Re: Fordson Theme - Embed responsive Videos by Vimeo

by Marcus Garvey -

Thank you very much Emma and Chris (not only for your kind responses, but also for creating and sharing this wonderful theme)!

I will try again in a few hours when I'm sure to not disturb currently logged in users and give you guys feedback if I succeeded. 

In reply to Marcus Garvey

Re: Fordson Theme - Embed responsive Videos by Vimeo

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

Well the fact you can see something means that the player is working and displaying OK 

The warning however suggests that the video is a cause of some type of violation.

Has your organisation blocked certain external Video resources?

I need to learn German!

Mary

Average of ratings: Useful (1)
In reply to Mary Evans

Re: Fordson Theme - Embed responsive Videos by Vimeo

by Marcus Garvey -

It worked out just FINE smile Thanks to all of you guys!

I will let you know when I've set up a Moodle course on learning German Mary :D 

Have a great day yall!