From 4f67ddd94ae15a4b1bbd626ab65092da1a761add Mon Sep 17 00:00:00 2001 From: stan Date: Tue, 15 Jul 2008 21:24:14 +0000 Subject: [PATCH] Fixed language selection git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@2528 e3e1d417-86f3-4887-817a-d78f3d33393f --- web/includes/functions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/includes/functions.php b/web/includes/functions.php index 62d11c2db..d97010742 100644 --- a/web/includes/functions.php +++ b/web/includes/functions.php @@ -1935,9 +1935,9 @@ function coordsToPoints( $coords ) function getLanguages() { $langs = array(); - foreach ( glob("zm_lang_*_*.php") as $file ) + foreach ( glob("lang/*_*.php") as $file ) { - preg_match( '/zm_lang_(.+_.+)\.php/', $file, $matches ); + preg_match( '/([^\/]+_.+)\.php/', $file, $matches ); $langs[$matches[1]] = $matches[1]; } return( $langs );