From: Greg Sabino Mullane Date: Mon, 26 Jun 2006 23:21:15 +0000 (+0000) Subject: Try language dir in two places, as sometimes we are not called from "config". X-Git-Tag: 1.31.0-rc.0~56584 X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin/?a=commitdiff_plain;h=5e80de74ab82e9687260630378034bd5b8eb9b40;p=lhc%2Fweb%2Fwiklou.git Try language dir in two places, as sometimes we are not called from "config". Fixes bug 5417. --- diff --git a/config/index.php b/config/index.php index 9042d80286..575b99790e 100644 --- a/config/index.php +++ b/config/index.php @@ -1388,6 +1388,9 @@ function getLanguageList() { $codes = array(); $d = opendir( "../languages" ); + /* In case we are called from the root directory */ + if (!$d) + $d = opendir( "languages"); while( false !== ($f = readdir( $d ) ) ) { $m = array(); if( preg_match( '/Language([A-Z][a-z_]+)\.php$/', $f, $m ) ) {