Browse Source

Mise a jour de soundcloud js pour utiliser le https tout le temps

Bastien Sevajol 11 years ago
parent
commit
3e5806e8a7
1 changed files with 10 additions and 1 deletions
  1. 10 1
      src/Muzich/CoreBundle/Resources/public/js/player/SoundCloudPlayer.js

+ 10 - 1
src/Muzich/CoreBundle/Resources/public/js/player/SoundCloudPlayer.js View File

@@ -3,7 +3,16 @@ function SoundCloudPlayer(ref_id, object_for_player, finish_callback, autoplay)
3 3
   autoplay = typeof autoplay !== 'undefined' ? autoplay : false;
4 4
   var _autoplay = autoplay;
5 5
   var _iframe_id = '';
6
-  var _ref_id = ref_id;
6
+  
7
+  if (typeof(ref_id) == 'string')
8
+  {
9
+    var _ref_id = ref_id.replace('http://', 'https://');
10
+  }
11
+  else
12
+  {
13
+    var _ref_id = ref_id
14
+  }
15
+  
7 16
   var _object_for_player = object_for_player;
8 17
   var _player = null;
9 18
   var _sounds_count = 0;