From 464141c72a48edfc693bd151c9598a6d84ca633a Mon Sep 17 00:00:00 2001 From: Giulio Gratta Date: Fri, 9 Aug 2013 09:24:17 -0700 Subject: [PATCH] changing http:// to // on intro video urls to prevent browsers from blocking video embeds --- cms/djangoapps/models/settings/course_details.py | 2 +- cms/static/js/models/settings/course_details.js | 2 +- lms/templates/index.html | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cms/djangoapps/models/settings/course_details.py b/cms/djangoapps/models/settings/course_details.py index 7c3b883283..78c5dcff33 100644 --- a/cms/djangoapps/models/settings/course_details.py +++ b/cms/djangoapps/models/settings/course_details.py @@ -173,7 +173,7 @@ class CourseDetails(object): # the right thing result = None if video_key: - result = '' return result diff --git a/cms/static/js/models/settings/course_details.js b/cms/static/js/models/settings/course_details.js index d7e11d5689..4d048bab81 100644 --- a/cms/static/js/models/settings/course_details.js +++ b/cms/static/js/models/settings/course_details.js @@ -75,7 +75,7 @@ CMS.Models.Settings.CourseDetails = Backbone.Model.extend({ return this.videosourceSample(); }, videosourceSample : function() { - if (this.has('intro_video')) return "http://www.youtube.com/embed/" + this.get('intro_video'); + if (this.has('intro_video')) return "//www.youtube.com/embed/" + this.get('intro_video'); else return ""; } }); diff --git a/lms/templates/index.html b/lms/templates/index.html index e7c0d638c7..0fecd24e84 100644 --- a/lms/templates/index.html +++ b/lms/templates/index.html @@ -186,7 +186,7 @@ else: youtube_video_id = "XNaiOGxWeto" %> - +