[Mapbender-commits] r4052 - branches/spsneo_dev/mapbender/update

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Fri Jun 19 10:50:45 EDT 2009


Author: christoph
Date: 2009-06-19 10:50:45 -0400 (Fri, 19 Jun 2009)
New Revision: 4052

Modified:
   branches/spsneo_dev/mapbender/update/updaters.inc
Log:


Modified: branches/spsneo_dev/mapbender/update/updaters.inc
===================================================================
--- branches/spsneo_dev/mapbender/update/updaters.inc	2009-06-19 14:50:06 UTC (rev 4051)
+++ branches/spsneo_dev/mapbender/update/updaters.inc	2009-06-19 14:50:45 UTC (rev 4052)
@@ -19,7 +19,24 @@
 	#select the database
 	db_select_db(DB,$con);
 	#locate the correct directory according to SYS_DBTYPE and CHARSET
-	$db_dir = dir(realpath(dirname(__FILE__).'/../resources/db/'.SYS_DBTYPE.'/'.CHARSET.'/update/'));
+
+	$tmpPath = dirname(__FILE__).'/../resources/db/';
+	if (SYS_DBTYPE == "pgsql") {
+		$tmpPath .= "postgresql/";
+	}
+	else {
+		$tmpPath .= "mysql/";
+	}
+	if (CHARSET == "UTF-8") {
+		$tmpPath .= "utf8/";
+	}
+	else {
+		$tmpPath .= "iso/";
+	}
+	$tmpPath .= 'update/';
+	$db_dir = dir(realpath($tmpPath));
+	echo $tmpPath;
+	
 	#Get the path of directory containing the sql files for later use in this function
 	$db_dir_path = $db_dir->path;
 	#this loops iterates for every file in the directory located



More information about the Mapbender_commits mailing list