From 39bcbf4db4629aacc23116fb7a473eb44690c4bc Mon Sep 17 00:00:00 2001 From: Alib Date: Sat, 27 Mar 2010 17:41:53 +0100 Subject: corrected path for rec and videos --- js/istreamdev.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'js') diff --git a/js/istreamdev.js b/js/istreamdev.js index 4aae3f8..f36b907 100644 --- a/js/istreamdev.js +++ b/js/istreamdev.js @@ -452,7 +452,7 @@ function gen_streamchannel(channame,channumber) { } function gen_streamrec(folder,path) { - var dataString = "action=getRecInfo&rec=" + encodeURIComponent(path) + "/" + encodeURIComponent(folder); + var dataString = "action=getRecInfo&rec=" + encodeURIComponent(path); //Json call to get rec info $.getJSON("bin/backend.php", dataString, @@ -470,7 +470,7 @@ function gen_streamrec(folder,path) { } function gen_streamvid(filename,path) { - var dataString = "action=getVidInfo&file=" + encodeURIComponent(path) + "/" + encodeURIComponent(filename); + var dataString = "action=getVidInfo&file=" + encodeURIComponent(path); //Json call to get rec info $.getJSON("bin/backend.php", dataString, @@ -617,10 +617,12 @@ $('ul[rel="filelist"] li[class="arrow"] a').tap(function(event) { } else if ( type == "rec" ) { + var path = $(this).find('span[class=filepath]').attr('rel'); gen_streamrec(name,path); } else if ( type == "video" ) { + var path = $(this).find('span[class=filepath]').attr('rel'); gen_streamvid(name,path); } return false; @@ -691,10 +693,10 @@ function gen_browser(path,browser,name,foldertype) { $("#browser" + browser).find('ul').append('
  • ' + list.name + '
  • '); } else if (list.type == "rec") { - $("#browser" + browser).find('ul').append('
  • ' + list.name + '
  • '); + $("#browser" + browser).find('ul').append('
  • ' + list.name + '
  • '); } else if ( list.type == "video" ) { - $("#browser" + browser).find('ul').append('
  • ' + list.name + '
  • '); + $("#browser" + browser).find('ul').append('
  • ' + list.name + '
  • '); } else if ( list.type == "audio" ) { if ( list.trackname != "" ) { -- cgit v1.2.3