]> source.dussan.org Git - nextcloud-server.git/commitdiff
some path fixes for multi-dir app
authorThomas Mueller <thomas.mueller@tmit.eu>
Fri, 22 Jun 2012 07:56:54 +0000 (09:56 +0200)
committerThomas Mueller <thomas.mueller@tmit.eu>
Fri, 22 Jun 2012 07:56:54 +0000 (09:56 +0200)
lib/app.php
lib/templatelayout.php

index 071ac83b4f299cb60122b0d81042267bdaf39229..486704a2229454548009fb5a8152de7fd7ba6fac 100755 (executable)
@@ -370,7 +370,7 @@ class OC_App{
        */
        public static function getAppWebPath($appid) {
                if( ($dir = self::findAppInDirectories($appid)) != false) {
-                       return $dir['url'].'/'.$appid;
+                       return OC::$WEBROOT.$dir['url'].'/'.$appid;
                }
        }
 
index 6e1d435f671c1b941998709a62c8bde30a1ebed1..d33a87e9e4c645270978135cf0375c9c3667e46b 100644 (file)
@@ -181,8 +181,8 @@ class OC_TemplateLayout extends OC_Template {
                                // Is it part of an app?
                                $append = false;
                                foreach( OC::$APPSROOTS as $apps_dir) {
-                                       if(self::appendIfExist($files, $apps_dir['path'], $apps_dir['url'], "$script$fext.js")) { $append =true; break; }
-                                       elseif(self::appendIfExist($files, $apps_dir['path'], $apps_dir['url'], "$script.js")) { $append =true; break; }
+                                       if(self::appendIfExist($files, $apps_dir['path'], OC::$WEBROOT.$apps_dir['url'], "$script$fext.js")) { $append =true; break; }
+                                       elseif(self::appendIfExist($files, $apps_dir['path'], OC::$WEBROOT.$apps_dir['url'], "$script.js")) { $append =true; break; }
                                }
                                if(! $append) {
                                        echo('js file not found: script:'.$script.' formfactor:'.$fext.' webroot:'.OC::$WEBROOT.' serverroot:'.OC::$SERVERROOT);