Fix music file action i.e. click to play, make OC.filePath act like OC_Helper::linkTo() for index.php links
This commit is contained in:
parent
20d9a8b6a1
commit
59a2616105
|
@ -1,6 +1,5 @@
|
|||
<?php
|
||||
if(!isset($_)){//allow the template to be loaded standalone
|
||||
require_once '../../../lib/base.php';
|
||||
$tmpl = new OCP\Template( 'media', 'player');
|
||||
$tmpl->printPage();
|
||||
exit;
|
||||
|
|
|
@ -54,11 +54,14 @@ OC={
|
|||
var isCore=OC.coreApps.indexOf(app)!=-1;
|
||||
var link=OC.webroot;
|
||||
if((file.substring(file.length-3) == 'php' || file.substring(file.length-3) == 'css') && !isCore){
|
||||
link+='/?app=' + app + '&getfile=';
|
||||
if(type){
|
||||
link+=encodeURI(type + '/');
|
||||
link+='/?app=' + app;
|
||||
if (file != 'index.php') {
|
||||
link+='&getfile=';
|
||||
if(type){
|
||||
link+=encodeURI(type + '/');
|
||||
}
|
||||
link+= file;
|
||||
}
|
||||
link+= file;
|
||||
}else if(file.substring(file.length-3) != 'php' && !isCore){
|
||||
link=OC.appswebroot;
|
||||
link+='/';
|
||||
|
|
Loading…
Reference in New Issue