updated player version.
authorhamidouk
Mon, 16 Jan 2012 09:56:08 +0100
changeset 395 557cefc119e9
parent 381 af6e95605934
child 396 134fe0c9e811
updated player version.
src/ldt/ldt/static/ldt/js/LdtPlayer-release.js
--- a/src/ldt/ldt/static/ldt/js/LdtPlayer-release.js	Fri Jan 13 16:24:16 2012 +0100
+++ b/src/ldt/ldt/static/ldt/js/LdtPlayer-release.js	Mon Jan 16 09:56:08 2012 +0100
@@ -1984,19 +1984,18 @@
             opts.streamer = "";
             var fullPath = IriSP.__jsonMetadata["medias"][0]["href"];
             var pathSplit = fullPath.split('/');
-            console.log(pathSplit);
             
             for (var i = 0; i < pathSplit.length; i++) {
               if (i < 4) {
                  opts.streamer += pathSplit[i] + "/";
               } else {
                  opts.file += pathSplit[i];
+                 /* omit the last slash if we're on the last element */
                  if (i < pathSplit.length - 1)
                   opts.file += "/";
               }
             }
-            
-            console.log(opts.file);
+
           } else {
             /* other providers type, video for instance -
                pass everything as is */
@@ -4585,7 +4584,15 @@
 
 /** return the id of the ligne de temps named "Chapitrage" */
 IriSP.JSONSerializer.prototype.getChapitrage = function() {
-  return this.getId("Chapitrage");
+  var val = this.getId("Chapitrage");
+  if (typeof(val) === "undefined")
+    val = this.getId("Chapter");   
+  if (typeof(val) === "undefined")
+    val = this.getId("Chapit");
+  if (typeof(val) === "undefined")
+    val = this.getId("Chap");
+    
+  return val;
 };
 
 /** return the id of the ligne de temps named "Tweets" */
@@ -4605,5 +4612,13 @@
 
 /** return the id of the ligne de temps named "Contributions" */
 IriSP.JSONSerializer.prototype.getContributions = function() {
-  return this.getId("Contributions");
+  var val = this.getId("Contribution");
+  if (typeof(val) === "undefined")
+    val = this.getId("Particip");   
+  if (typeof(val) === "undefined")
+    val = this.getId("Contr");
+  if (typeof(val) === "undefined")
+    val = this.getId("Publ");
+    
+  return val;
 };
\ No newline at end of file