From b5e3e150eb9737022d0c9080e84bac4d290c96a7 Mon Sep 17 00:00:00 2001 From: Brice Maron Date: Fri, 22 Jun 2012 20:58:28 +0000 Subject: [PATCH] Correction of path looking for apps and css --- apps/contacts/css/jquery.Jcrop.css | 2 +- lib/db.php | 2 +- lib/migrate.php | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/apps/contacts/css/jquery.Jcrop.css b/apps/contacts/css/jquery.Jcrop.css index c9b24a5ebe..a9ba4746e0 100644 --- a/apps/contacts/css/jquery.Jcrop.css +++ b/apps/contacts/css/jquery.Jcrop.css @@ -14,7 +14,7 @@ } .jcrop-vline, .jcrop-hline { - background: white url('%webroot%/apps/contacts/img/Jcrop.gif') top left repeat; + background: white url('%appswebroot%/contacts/img/Jcrop.gif') top left repeat; font-size: 0px; position: absolute; } diff --git a/lib/db.php b/lib/db.php index bcc8657b4a..dc9e3392d0 100644 --- a/lib/db.php +++ b/lib/db.php @@ -526,7 +526,7 @@ class OC_DB { self::removeDBStructure( OC::$SERVERROOT . '/db_structure.xml' ); foreach($apps as $app){ - $path = OC::$SERVERROOT.'/apps/'.$app.'/appinfo/database.xml'; + $path = self::getAppPath($app).'/appinfo/database.xml'; if(file_exists($path)){ self::removeDBStructure( $path ); } diff --git a/lib/migrate.php b/lib/migrate.php index 5939ba32e5..f26b4b2567 100644 --- a/lib/migrate.php +++ b/lib/migrate.php @@ -64,7 +64,7 @@ class OC_Migrate{ $apps = OC_App::getAllApps(); foreach($apps as $app){ - $path = OC::$SERVERROOT . '/apps/' . $app . '/appinfo/migrate.php'; + $path = self::getAppPath($app) . '/appinfo/migrate.php'; if( file_exists( $path ) ){ include( $path ); } @@ -398,7 +398,7 @@ class OC_Migrate{ if( OC_App::isEnabled( $provider->getID() ) ){ $success = true; // Does this app use the database? - if( file_exists( OC::$SERVERROOT.'/apps/'.$provider->getID().'/appinfo/database.xml' ) ){ + if( file_exists( self::getAppPath($provider->getID()).'/appinfo/database.xml' ) ){ // Create some app tables $tables = self::createAppTables( $provider->getID() ); if( is_array( $tables ) ){ @@ -539,7 +539,7 @@ class OC_Migrate{ } // There is a database.xml file - $content = file_get_contents( OC::$SERVERROOT . '/apps/' . $appid . '/appinfo/database.xml' ); + $content = file_get_contents(self::getAppPath($appid) . '/appinfo/database.xml' ); $file2 = 'static://db_scheme'; // TODO get the relative path to migration.db from the data dir @@ -608,7 +608,7 @@ class OC_Migrate{ static public function getApps(){ $allapps = OC_App::getAllApps(); foreach($allapps as $app){ - $path = OC::$SERVERROOT . '/apps/' . $app . '/lib/migrate.php'; + $path = self::getAppPath($app) . '/lib/migrate.php'; if( file_exists( $path ) ){ $supportsmigration[] = $app; }