[Mapbender-commits] r2602 - in branches: 2.5/http 2.5/http/frames
2.5/http/include 2.5/http/php testbaudson_dev/core
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Tue Jul 8 08:33:56 EDT 2008
Author: christoph
Date: 2008-07-08 08:33:55 -0400 (Tue, 08 Jul 2008)
New Revision: 2602
Modified:
branches/2.5/http/frames/index.php
branches/2.5/http/frames/login.php
branches/2.5/http/include/dyn_js.php
branches/2.5/http/index.php
branches/2.5/http/php/mb_listGUIs.php
branches/2.5/http/php/mb_validateSession.php
branches/testbaudson_dev/core/globalSettings.php
Log:
latest i18n
Modified: branches/2.5/http/frames/index.php
===================================================================
--- branches/2.5/http/frames/index.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/frames/index.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -18,9 +18,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-mb_internal_encoding("UTF-8");
require("../php/mb_validateSession.php");
-require_once(dirname(__FILE__)."/../classes/class_locale.php");
//
// check if user is allowed to access current GUI;
@@ -32,17 +30,10 @@
die();
}
-#$e = new mb_notice("index.php: arguments: GML: " . $_SESSION["GML"]);
-#$e = new mb_notice("index.php: arguments: Zoom to layer: " . $_REQUEST["zoomToLayer"]);
-#$e = new mb_notice("index.php: arguments: portal_services: " . $_REQUEST["portal_services"]);
-#$e = new mb_notice("index.php: arguments: portal_services_wfs: " . $_REQUEST["portal_services_wfs"]);
-#$e = new mb_notice("index.php: arguments: layer_preview: " . $_REQUEST["layer_preview"]);
-
$pattern = "/sessionID/";
$_SESSION["mb_user_gui"] = $gui_id;
-$localeObj = new Mb_locale($_SESSION["mb_lang"]);
@@ -167,4 +158,4 @@
echo "<script type='text/javascript' src='../javascripts/map.php?".$urlParameters."&mb_myBBOX=".$_REQUEST["mb_myBBOX"]."'></script>";
?>
</body>
-</html>
\ No newline at end of file
+</html>
Modified: branches/2.5/http/frames/login.php
===================================================================
--- branches/2.5/http/frames/login.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/frames/login.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -17,9 +17,7 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
ob_start();
-include_once(dirname(__FILE__)."/../../conf/mapbender.conf");
-$con = db_connect(DBSERVER,OWNER,PW);
-db_select_db(DB,$con);
+require_once(dirname(__FILE__)."/../../core/globalSettings.php");
function auth_user($name,$pw){
$setEncPw = false;
Modified: branches/2.5/http/include/dyn_js.php
===================================================================
--- branches/2.5/http/include/dyn_js.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/include/dyn_js.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -17,6 +17,8 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+require_once(dirname(__FILE__)."/../classes/class_mb_exception.php");
+
if(isset($gui_id))
{
$sql = "SELECT * FROM gui_element_vars WHERE fkey_e_id = $1 AND fkey_gui_id = $2 and var_type='var'";
@@ -47,4 +49,7 @@
}
}
}
-?>
\ No newline at end of file
+else {
+ $e = new mb_exception("Application ID not set while retrieving element vars of module " . $e_id);
+}
+?>
Modified: branches/2.5/http/index.php
===================================================================
--- branches/2.5/http/index.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/index.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -18,7 +18,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-include_once(dirname(__FILE__)."/php/system.php");
+include_once(dirname(__FILE__)."/../core/system.php");
?>
<!DOCTYPE HTML PUBLIC "-//W3C//Dtd HTML 4.01 Transitional//EN">
<html>
Modified: branches/2.5/http/php/mb_listGUIs.php
===================================================================
--- branches/2.5/http/php/mb_listGUIs.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/php/mb_listGUIs.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -36,7 +36,7 @@
}
$sql_list_guis .= ") ORDER BY gui_name";
$res_list_guis = db_prep_query($sql_list_guis,$v,$t);
- if ($_SESSION["mb_user_name"] != "test" && $_SESSION["mb_user_name"] != "demo") {
+ if ($_SESSION["mb_user_name"] != "test" && $_SESSION["mb_user_name"] != "demo" && $_SESSION["mb_user_name"] != "guest") {
echo "<a href=\"../php/mod_editSelf.php?".SID."\" class='list_guis' target=_blank>Change personal settings</a>";
}
echo "</td><td align = 'right'>";
Modified: branches/2.5/http/php/mb_validateSession.php
===================================================================
--- branches/2.5/http/php/mb_validateSession.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/2.5/http/php/mb_validateSession.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -17,18 +17,9 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-session_start();
+require_once(dirname(__FILE__)."/../../core/globalSettings.php");
-require_once(dirname(__FILE__)."/../php/system.php");
-require_once(dirname(__FILE__)."/../../conf/mapbender.conf");
-require_once(dirname(__FILE__)."/../classes/class_mb_exception.php");
-//
-// establish database connection
-//
-$con = db_connect($DBSERVER, $OWNER, $PW);
-db_select_db(DB, $con);
-
$e = new mb_notice("mb_validateSession.php: checking file " . $_SERVER["PHP_SELF"]);
//
@@ -49,12 +40,12 @@
if (!$gui_id) {
$e = new mb_notice("gui id not set");
if ($_REQUEST["guiID"]) {
- $e = new mb_notice("gui id set to guiID");
$gui_id = $_REQUEST["guiID"];
+ $e = new mb_notice("gui id set to guiID: " . $gui_id);
}
elseif ($_REQUEST["gui_id"]) {
- $e = new mb_notice("gui id set to gui_id");
$gui_id = $_REQUEST["gui_id"];
+ $e = new mb_notice("gui id set to gui_id: " . $gui_id);
}
else {
$e = new mb_notice("mb_validateSession.php: gui_id not set in script: " . $_SERVER["PHP_SELF"]);
Modified: branches/testbaudson_dev/core/globalSettings.php
===================================================================
--- branches/testbaudson_dev/core/globalSettings.php 2008-07-08 12:18:22 UTC (rev 2601)
+++ branches/testbaudson_dev/core/globalSettings.php 2008-07-08 12:33:55 UTC (rev 2602)
@@ -23,23 +23,23 @@
// database wrapper
//
if(SYS_DBTYPE=="mysql") {
- require_once(dirname(__FILE__) . "/../lib/database-mysql.php");
+ require_once(dirname(__FILE__) . "/../http/php/database-mysql.php");
}
else {
- require_once(dirname(__FILE__) . "/../lib/database-pgsql.php");
+ require_once(dirname(__FILE__) . "/../http/php/database-pgsql.php");
}
//
// class for error handling
//
-require_once(dirname(__FILE__)."/../lib/exception.php");
+require_once(dirname(__FILE__)."/../http/classes/class_exception.php");
//
// I18n wrapper function, gettext
//
require_once(dirname(__FILE__) . "/../core/i18n.php");
-require_once(dirname(__FILE__) . "/../lib/locale.php");
+require_once(dirname(__FILE__) . "/../http/classes/class_locale.php");
$localeObj = new Mb_locale($_SESSION["mb_lang"]);
More information about the Mapbender_commits
mailing list