[Mapbender-commits] r7293 - in trunk/mapbender/http: extensions php

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Sun Dec 12 07:36:38 EST 2010


Author: christoph
Date: 2010-12-12 04:36:38 -0800 (Sun, 12 Dec 2010)
New Revision: 7293

Removed:
   trunk/mapbender/http/extensions/markResult.php
   trunk/mapbender/http/php/mod_zoomCoords.php
   trunk/mapbender/http/php/mod_zoomCoords_en.php
Log:
http://www.mapbender.org/Talk:Import_request_variables

Deleted: trunk/mapbender/http/extensions/markResult.php
===================================================================
--- trunk/mapbender/http/extensions/markResult.php	2010-12-12 12:35:45 UTC (rev 7292)
+++ trunk/mapbender/http/extensions/markResult.php	2010-12-12 12:36:38 UTC (rev 7293)
@@ -1,71 +0,0 @@
-<?PHP
-# $Id$
-# http://www.mapbender.org/index.php/markResult.php
-# Copyright (C) 2002 CCGIS 
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-/*
-* following parameters are required:
-* $width, $height ->  dimensions of the image
-* $color -> Color of the polygon/line, commasaparated RGB-values
-*
-*/
-
-
-/*  
- * @security_patch irv open 
- */ 
-security_patch_log(__FILE__,__LINE__); 
-import_request_variables("PG"); 
-
-
-require(dirname(__FILE__)."/../php/mb_validateSession.php");
-$tmpx = array();
-$tmpy = array();
-$x = array();
-$y = array();
-$tmpx = explode(":", $_REQUEST["x"]);
-$tmpy = explode(":", $_REQUEST["y"]);
-for($i=0; $i<count($tmpx); $i++){
-	$x[$i] = array();
-	$y[$i] = array();
-	$x[$i] = explode(",",$tmpx[$i]);
-	$y[$i] = explode(",",$tmpy[$i]);	
-}
-
-if(!$_REQUEST["color"]){ $color = "255,0,0"; }
-$myCol = mb_split(",", $color);
-
-$image = imagecreate($width,$height);
-
-$transparent = ImageColorAllocate($image,155,155,155); 
-ImageFilledRectangle($image,0,0,$width,$height,$transparent); 
-ImageColorTransparent ($image , $transparent);
-
-  
-$red = imagecolorallocate($image,$myCol[0],$myCol[1],$myCol[2]); 
-for($j=0; $j<count($x); $j++){
-	for($i=0; $i < (count($x[$j])-1); $i++){
-		imageline($image,$x[$j][$i],$y[$j][$i],$x[$j][$i+1],$y[$j][$i+1],$red);
-		imageline($image,$x[$j][$i]+1,$y[$j][$i],$x[$j][$i+1]+1,$y[$j][$i+1],$red);
-		imageline($image,$x[$j][$i]-1,$y[$j][$i],$x[$j][$i+1]-1,$y[$j][$i+1],$red);
-		imageline($image,$x[$j][$i],$y[$j][$i]+1,$x[$j][$i+1],$y[$j][$i+1]+1,$red);
-		imageline($image,$x[$j][$i],$y[$j][$i]-1,$x[$j][$i+1],$y[$j][$i+1]-1,$red);	
-	} 
-}
-header("Content-Type: image/png"); 
-imagepng($image); 
-?>

Deleted: trunk/mapbender/http/php/mod_zoomCoords.php
===================================================================
--- trunk/mapbender/http/php/mod_zoomCoords.php	2010-12-12 12:35:45 UTC (rev 7292)
+++ trunk/mapbender/http/php/mod_zoomCoords.php	2010-12-12 12:36:38 UTC (rev 7293)
@@ -1,107 +0,0 @@
-<?php
-#$Id$
-# http://www.mapbender.org/Mapbender_without_iframes
-# Copyright (C) 2002 CCGIS 
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# 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");
-include(dirname(__FILE__)."/../include/dyn_js.php");
-?>
-try{
-	if (zoomCoords_permanentHighlight){}
-}
-catch(e){
-	zoomCoords_permanentHighlight = 'false';
-}
-
-var mod_zoomCoords_target = '<?php echo $e_target[0];?>';
-mod_zoomCoords_target = mod_zoomCoords_target.split(',');
-
-function zoomCoordinate(x,y){
-   x=x.replace(",",".");
-   y=y.replace(",",".");
-   
-   document.zoomCoordsForm.X.value=x;
-   document.zoomCoordsForm.Y.value=y;
-	  
-   if (isNaN(x)==true || isNaN(y)==true){
-       alert ("<?php echo _mb("Please type a number.");?>");
-   }else{
-   
-	   if(zoomCoords_permanentHighlight =='true'){
-		   setPermanentMarker(x,y);
-	   }
-  		hideHighlightZoomcoords()
-      	zoom(mod_zoomCoords_target[0],true, 1.0,x,y);
-   }
-}
-
-function highlightZoomcoords(x, y){
-	if(x!='' && y!=''){   
-	   x=x.replace(",",".");
-	   y=y.replace(",",".");
-	   
-	   document.zoomCoordsForm.X.value=x;
-	   document.zoomCoordsForm.Y.value=y;
-	  
-	   
-	   if (isNaN(x)==true || isNaN(y)==true){
-	     
-	   }
-	   else{
-			for(var i=0;i<mod_zoomCoords_target.length;i++){
-				mb_showHighlight(mod_zoomCoords_target[i],x,y);
-			}
-	   }
-	}
-}
-
-
-function hideHighlightZoomcoords(){
-	for(var i=0;i<mod_zoomCoords_target.length;i++){
-		mb_hideHighlight(mod_zoomCoords_target[i]);
-	}
-}
-
-function setPermanentMarker(x,y){
- 	mod_permanentHighlight_x = parseFloat(x);
-   	mod_permanentHighlight_y = parseFloat(y);
-   	mod_permanentHighlight_text = x + ' / '+ y;
-  
-   	mod_permanentHighlight_init();
-}
-
-parent.eventInitMap.register(function zoomCoorsInit(){
-	var el = document.getElementById("zoomCoords");
-	if(el){
-		el.innerHTML="<?php
-echo "<form style='font-family : Arial, Helvetica, sans-serif;font-size: 11px;' name='zoomCoordsForm' action='" . $_SERVER["SCRIPT_NAME"] . "?".SID."' method='post'>";
-#coordinates
-   
-   # Deutsche Version
-
-   # English Version
-      echo "<span style='position: absolute;left: 5px;top:5px;color: Gray;'>"._mb("Longitude").":</span>";
-      echo "<span style='position: absolute;left: 80px;top:5px;color: Gray;'>"._mb("Latitude").":</span>";
-      echo "<input style='position: absolute;left:5px;top:20px;color: Gray;width:65px;border: solid thin;height:20px;' type='text' name='X'>";
-      echo "<input style='position: absolute;left:80px;top:20px;color: Gray;width:65px;border: solid thin;height:20px;'class='texty' type='text' name='Y'>";
-      echo "<input style='position: absolute;left:150px;top:20px;color: Gray;border: solid thin;height:20px;' type='button' value='"._mb("ok")."' onclick='zoomCoordinate(document.zoomCoordsForm.X.value, document.zoomCoordsForm.Y.value); highlightZoomcoords(document.zoomCoordsForm.X.value, document.zoomCoordsForm.Y.value)' onmouseover='highlightZoomcoords(document.zoomCoordsForm.X.value, document.zoomCoordsForm.Y.value)' onmouseout='hideHighlightZoomcoords(document.zoomCoordsForm.X.value, document.zoomCoordsForm.Y.value)' >";
-
-echo "</form>";
-?>";
-	}
-});
-

Deleted: trunk/mapbender/http/php/mod_zoomCoords_en.php
===================================================================
--- trunk/mapbender/http/php/mod_zoomCoords_en.php	2010-12-12 12:35:45 UTC (rev 7292)
+++ trunk/mapbender/http/php/mod_zoomCoords_en.php	2010-12-12 12:36:38 UTC (rev 7293)
@@ -1,186 +0,0 @@
-<?php
-# $Id$
-# http://www.mapbender.org/index.php/Administration
-# Copyright (C) 2002 CCGIS 
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# 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");
-/*
- * @security_patch irv open
- */
-security_patch_log(__FILE__,__LINE__); 
-import_request_variables("PG"); 
-
-?>
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
-<meta http-equiv="cache-control" content="no-cache">
-<meta http-equiv="pragma" content="no-cache">
-<meta http-equiv="expires" content="0">
-<?php
-echo '<meta http-equiv="Content-Type" content="text/html; charset='.CHARSET.'">';	
-?>
-<title>Zoom to Coordinate</title>
-<style type="text/css">
-	    <!--
-
-	    body{
-	    	font-family : Arial, Helvetica, sans-serif;
-	    	font-size: 11px;
-	    }
-	    .labelx{
-	    	position: absolute;
-	    	left: 5px;
-	    	top:5px;
-	    	color: Gray;
-	    }
-	    .labely{
-	    	position: absolute;
-	    	left: 90px;
-	    	top:5px;
-	    	color: Gray;
-	    }
-	    .textx{
-	    	position: absolute;
-	    	left:5px;
-	    	top:20px;
-	    	color: Gray;
-	    	width:70px;
-         border: solid thin;
-         height:20px;
-	    }
-	    .texty{
-	    	position: absolute;
-	    	left:90px;
-	    	top:20px;
-         color: Gray;
-	    	width:70px;
-         border: solid thin;
-         height:20px;
-	    }
-       .send{
-  	    	position: absolute;
-	    	left:177px;
-	    	top:20px;
-         color: Gray;
-         border: solid thin;
-         height:20px;
-         width:30px;
-       }
-	    -->
-</style>
-<?php
-echo '<script type="text/javascript">';
-
-echo "var mod_zoomCoords_target = '".$e_target."';";
-echo "var target = mod_zoomCoords_target.split(',');";
-
-
-include(dirname(__FILE__)."/../include/dyn_js.php");
-
-?>
-try{
-	if (zoomCoords_permanentHighlight){}
-}
-catch(e){
-	zoomCoords_permanentHighlight = 'false';
-}
-
-
-function zoomCoordinate(){
-   var coordx = document.form1.X.value; 
-   var coordy = document.form1.Y.value;
-   coordx = coordx.replace(",",".");
-   coordy = coordy.replace(",",".");
-   var valid = true;
-    
- /*  if(parseFloat(coordx) < 5.88 ||  parseFloat(coordx) > 15){
-      alert("Eingabe unzulässig!");
-      document.form1.X.select();
-      document.form1.X.focus();
-      valid = false; 
-      return false;
-   }
-   if(parseFloat(coordy) < 46.62 ||  parseFloat(coordy) > 55.71){
-      alert("Eingabe unzulässig!");
-      document.form1.Y.select();
-      document.form1.Y.focus();
-      valid = false;
-      return false;
-   }   */
-   
-   if(zoomCoords_permanentHighlight =='true'){
-	   setPermanentMarker(coordx,coordy);
-   }
-   parent.mb_hideHighlight(target[0]);
-   parent.mb_hideHighlight(target[1]);
-   parent.zoom(target[0],true, 1.0,coordx,coordy);
-  
-}
-
-function highlight(x, y){
-	if(x!='' && y!=''){
-       x=x.replace(",",".");
-	   y=y.replace(",",".");
-	   
-	   document.form1.X.value=x;
-	   document.form1.Y.value=y;
-	   
-	   if (isNaN(x)==true || isNaN(y)==true){
-	     
-	   }
-	   else{
-	      parent.mb_showHighlight(target[0],x,y);
-	      parent.mb_showHighlight(target[1],x,y);
-	   }
-	}   
-}
-
-function hideHighlight(){
-   parent.mb_hideHighlight(target[0]);
-   parent.mb_hideHighlight(target[1]);
-}
-
-function setPermanentMarker(x,y){
-   parent.mod_permanentHighlight_x = parseFloat(x);
-   parent.mod_permanentHighlight_y = parseFloat(y);
-   parent.mod_permanentHighlight_text = x + ' / '+ y;
-   //alert('setPermanentMarker'+ parseFloat(x) + parseFloat(y));
-   
-   parent.mod_permanentHighlight_init();
-}
-// -->
-</script>
-</head>
-<body bgcolor='#ffffff' onload=''>
-
-<?php
-echo "<form name='form1' action='" . $self ."' method='post'>";
-#coordinates
-   
-   #deutsche Version
-      echo "<span class='labelx'>X-Coordinate:</span>";
-      echo "<span class='labely'>Y-Coordinate:</span>";
-      echo "<input class='textx' type='text' name='X'>";
-      echo "<input class='texty' type='text' name='Y'>";
-      echo "<input class='send' type='button' value='ok' onclick='zoomCoordinate();' onmouseover='highlight(document.form1.X.value, document.form1.Y.value)' onmouseout='if(document.form1.X.value !=\"\" && document.form1.Y.value !=\"\"){hideHighlight(document.form1.X.value, document.form1.Y.value);}' >";
-
-?>
-</form>
-</body>
-</html>



More information about the Mapbender_commits mailing list