[Mapbender-commits] r2238 - branches/2.5/http/javascripts
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Thu Mar 13 10:24:56 EDT 2008
Author: christoph
Date: 2008-03-13 10:24:56 -0400 (Thu, 13 Mar 2008)
New Revision: 2238
Modified:
branches/2.5/http/javascripts/mod_back.php
branches/2.5/http/javascripts/mod_center1.php
branches/2.5/http/javascripts/mod_resize_mapsize.php
branches/2.5/http/javascripts/mod_savewmc.php
branches/2.5/http/javascripts/mod_scaleHint.php
branches/2.5/http/javascripts/mod_scaleSel.php
branches/2.5/http/javascripts/mod_scaleText.php
branches/2.5/http/javascripts/mod_scalebar.php
branches/2.5/http/javascripts/mod_selArea.php
branches/2.5/http/javascripts/mod_selArea1.php
branches/2.5/http/javascripts/mod_setBBOX1.php
branches/2.5/http/javascripts/mod_setBackground.php
branches/2.5/http/javascripts/mod_setBackground_all.php
branches/2.5/http/javascripts/mod_setPOI2Scale.php
branches/2.5/http/javascripts/mod_tab.php
branches/2.5/http/javascripts/mod_toggleModule.php
branches/2.5/http/javascripts/mod_wfs_SpatialRequest.php
branches/2.5/http/javascripts/mod_wfs_gazetteer_client.php
branches/2.5/http/javascripts/mod_zoomFull.php
branches/2.5/http/javascripts/mod_zoomIn1.php
branches/2.5/http/javascripts/mod_zoomOut1.php
Log:
added validatePermission
Modified: branches/2.5/http/javascripts/mod_back.php
===================================================================
--- branches/2.5/http/javascripts/mod_back.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_back.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_back_map = '".$e_target[0]."';";
echo "var mod_back_overview = '".$e_target[1]."';";
Modified: branches/2.5/http/javascripts/mod_center1.php
===================================================================
--- branches/2.5/http/javascripts/mod_center1.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_center1.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_center_target = '".$e_target[0]."';";
?>
Modified: branches/2.5/http/javascripts/mod_resize_mapsize.php
===================================================================
--- branches/2.5/http/javascripts/mod_resize_mapsize.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_resize_mapsize.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -20,7 +20,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
include(dirname(__FILE__) . "/../include/dyn_js.php");
$sqltarget = "SELECT e_target FROM gui_element WHERE e_id = 'resizeMapsize' AND fkey_gui_id = $1";
Modified: branches/2.5/http/javascripts/mod_savewmc.php
===================================================================
--- branches/2.5/http/javascripts/mod_savewmc.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_savewmc.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
include(dirname(__FILE__) . "/../include/dyn_js.php");
echo "mod_savewmc_target = '".$e_target[0]."';";
Modified: branches/2.5/http/javascripts/mod_scaleHint.php
===================================================================
--- branches/2.5/http/javascripts/mod_scaleHint.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_scaleHint.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_scaleHint_target = '".$e_target[0]."';";
echo "var mod_scaleHint_min = '".$e_target[1]."';";
Modified: branches/2.5/http/javascripts/mod_scaleSel.php
===================================================================
--- branches/2.5/http/javascripts/mod_scaleSel.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_scaleSel.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_scaleSelect_target = '".$e_target[0]."';";
?>
mb_registerSubFunctions("mod_scaleSelect_val(frameName)");
Modified: branches/2.5/http/javascripts/mod_scaleText.php
===================================================================
--- branches/2.5/http/javascripts/mod_scaleText.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_scaleText.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_scaleText_target = '".$e_target[0]."';";
?>
function mod_scaleText(){
Modified: branches/2.5/http/javascripts/mod_scalebar.php
===================================================================
--- branches/2.5/http/javascripts/mod_scalebar.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_scalebar.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_scalebar_target = '".$e_target[0]."';";
?>
Modified: branches/2.5/http/javascripts/mod_selArea.php
===================================================================
--- branches/2.5/http/javascripts/mod_selArea.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_selArea.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
?>
var mod_selArea_elName = "selArea1";
var mod_selArea_frameName = "";
Modified: branches/2.5/http/javascripts/mod_selArea1.php
===================================================================
--- branches/2.5/http/javascripts/mod_selArea1.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_selArea1.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
?>
var mod_selArea_elName = "selArea1";
var mod_selArea_frameName = "";
Modified: branches/2.5/http/javascripts/mod_setBBOX1.php
===================================================================
--- branches/2.5/http/javascripts/mod_setBBOX1.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_setBBOX1.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_setBBOX_target = '".$e_target[0]."';";
?>
mb_registerInitFunctions("mod_setBBOX_init()");
Modified: branches/2.5/http/javascripts/mod_setBackground.php
===================================================================
--- branches/2.5/http/javascripts/mod_setBackground.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_setBackground.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
if(isset($_REQUEST["wms"])){
$wms = $_REQUEST["wms"];
}
Modified: branches/2.5/http/javascripts/mod_setBackground_all.php
===================================================================
--- branches/2.5/http/javascripts/mod_setBackground_all.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_setBackground_all.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -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.
-require_once(dirname(__FILE__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_setBackground_all_target = '".$e_target[0]."';";
?>
Modified: branches/2.5/http/javascripts/mod_setPOI2Scale.php
===================================================================
--- branches/2.5/http/javascripts/mod_setPOI2Scale.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_setPOI2Scale.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_setPOI2Scale_target = '".$e_target[0]."';";
include(dirname(__FILE__) . "/../include/dyn_js.php");
Modified: branches/2.5/http/javascripts/mod_tab.php
===================================================================
--- branches/2.5/http/javascripts/mod_tab.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_tab.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -19,7 +19,7 @@
/********** Configuration*************************************************/
-require_once(dirname(__FILE__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
require_once(dirname(__FILE__)."/../extensions/JSON.php");
include(dirname(__FILE__)."/../include/dyn_js.php");
Modified: branches/2.5/http/javascripts/mod_toggleModule.php
===================================================================
--- branches/2.5/http/javascripts/mod_toggleModule.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_toggleModule.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
echo "var mod_toggleModule ='".$e_target[0]."';";
?>
mb_registerInitFunctions('mod_toggleModule_init()');
Modified: branches/2.5/http/javascripts/mod_wfs_SpatialRequest.php
===================================================================
--- branches/2.5/http/javascripts/mod_wfs_SpatialRequest.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_wfs_SpatialRequest.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,10 +17,16 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
$wfs_conf_filename = "wfs_default.conf";
include '../include/dyn_php.php';
-include(dirname(__FILE__) . "/../../conf/" . $wfs_conf_filename);
+$fname = dirname(__FILE__) . "/../../conf/" . $wfs_conf_filename;
+if (file_exists($fname)) {
+ include($fname);
+}
+else {
+ $e = new mb_exception("mod_wfs_SpatialRequest.php: Configuration file " . $wfs_conf_filename . " not found.");
+}
include '../include/dyn_js.php';
echo "var mod_wfs_spatialRequest_target = '".$e_target[0]."';\n";
Modified: branches/2.5/http/javascripts/mod_wfs_gazetteer_client.php
===================================================================
--- branches/2.5/http/javascripts/mod_wfs_gazetteer_client.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_wfs_gazetteer_client.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -18,18 +18,12 @@
# 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__)."/../php/mb_validatePermission.php");
+
$gui_id = $_SESSION["mb_user_gui"];
-
$target = $_REQUEST["e_target"];
-$e_id_css = $_REQUEST["e_id_css"];
-$e_id = $_REQUEST["e_id"];
$isLoaded = $_REQUEST["isLoaded"];
-require_once(dirname(__FILE__) . "/../../conf/mapbender.conf");
-
-$con = db_connect($DBSERVER,$OWNER,$PW);
-db_select_db($DB,$con);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
@@ -44,7 +38,13 @@
<?php
include '../include/dyn_js.php';
include '../include/dyn_php.php';
- include("../../conf/" . $wfs_spatial_request_conf_filename);
+ $fname = dirname(__FILE__) . "/../../conf/" . $wfs_spatial_request_conf_filename;
+ if (file_exists($fname)) {
+ include($fname);
+ }
+ else {
+ $e = new mb_exception("mod_wfs_gazetteer_client.php: Configuration file " . $wfs_spatial_request_conf_filename . " not found.");
+ }
echo "var targetString = '" . $target . "';";
echo "var wfsConfIdString = '" . $wfsConfIdString . "';";
Modified: branches/2.5/http/javascripts/mod_zoomFull.php
===================================================================
--- branches/2.5/http/javascripts/mod_zoomFull.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_zoomFull.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -1,7 +1,7 @@
<?php
#$Id$
#$Header: /cvsroot/mapbender/mapbender/http/javascripts/mod_zoomFull.php,v 1.8 2005/09/13 18:16:42 bjoern_heuser Exp $
-require_once(dirname(__FILE__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
?>
var mod_zoomFull_img = new Image();
mod_zoomFull_img.src = "<?php echo $e_src; ?>";
Modified: branches/2.5/http/javascripts/mod_zoomIn1.php
===================================================================
--- branches/2.5/http/javascripts/mod_zoomIn1.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_zoomIn1.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -17,7 +17,7 @@
# 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__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
?>
var mod_zoom1_img = new Image();
mod_zoom1_img.src = "<?php echo $e_src; ?>";
Modified: branches/2.5/http/javascripts/mod_zoomOut1.php
===================================================================
--- branches/2.5/http/javascripts/mod_zoomOut1.php 2008-03-13 14:23:05 UTC (rev 2237)
+++ branches/2.5/http/javascripts/mod_zoomOut1.php 2008-03-13 14:24:56 UTC (rev 2238)
@@ -2,7 +2,7 @@
#$Id$
#$Header: /cvsroot/mapbender/mapbender/http/javascripts/mod_zoomOut1.php,v 1.8 2005/09/13 18:16:42 bjoern_heuser Exp $
-require_once(dirname(__FILE__)."/../php/mb_validateSession.php");
+require_once(dirname(__FILE__)."/../php/mb_validatePermission.php");
?>
var mod_zoomOut_img = new Image();
mod_zoomOut_img.src = "<?php echo $e_src; ?>";
More information about the Mapbender_commits
mailing list