[Mapbender-commits] r1457 - trunk/mapbender/http/php
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Thu Jun 14 05:00:30 EDT 2007
Author: christoph
Date: 2007-06-14 05:00:30 -0400 (Thu, 14 Jun 2007)
New Revision: 1457
Modified:
trunk/mapbender/http/php/mod_wfs_edit.php
Log:
*added column "auth"
*different display (vertical table header)
Modified: trunk/mapbender/http/php/mod_wfs_edit.php
===================================================================
--- trunk/mapbender/http/php/mod_wfs_edit.php 2007-06-13 10:06:18 UTC (rev 1456)
+++ trunk/mapbender/http/php/mod_wfs_edit.php 2007-06-14 09:00:30 UTC (rev 1457)
@@ -130,7 +130,9 @@
if(!empty($_REQUEST["f_mandatory".$i])){
$sql .= '1';
}else{$sql .= '0';}
- $sql .= "' ";
+ $sql .= "', ";
+ $sql .= "f_auth_varname = '".addslashes($_REQUEST["f_auth_varname".$i]);
+ $sql .= "'";
$sql .= " WHERE fkey_wfs_conf_id = ".$_REQUEST["gaz"]." AND f_id = ".$_REQUEST["f_id".$i].";";
$res = db_query($sql);
}
@@ -158,8 +160,11 @@
/* end select wfs */
+function toImage($text) {
+ $angle = 90;
+ return "<img src='../php/createImageFromText.php?text=" . urlencode($text) . "&angle=" . $angle . "'>";
+}
-
/* configure elements */
if(isset($_REQUEST["gaz"])){
$sql = "SELECT * FROM wfs_conf WHERE wfs_conf_id = ".$_REQUEST["gaz"];
@@ -187,52 +192,47 @@
$sql .= "WHERE fkey_wfs_conf_id = ".$_REQUEST["gaz"];
$res = db_query($sql);
-
+
echo "<table border='1'>";
- echo "<tr>";
- echo "<td>ID</td>";
- echo "<td>name</td>";
- echo "<td>type</td>";
- echo "<td>geom</td>";
- echo "<td>gid</td>";
- echo "<td>search</td>";
- echo "<td>pos</td>";
- echo "<td>style_id</td>";
- echo "<td>upper</td>";
- echo "<td>label</td>";
- echo "<td>label_id</td>";
- echo "<td>show</td>";
- echo "<td>position</td>";
- echo "<td>mandatory</td>";
- echo "<td>edit</td>";
- echo "<td>html</td>";
+ echo "<tr valign = bottom>";
+ echo "<td>" . toImage('ID') . "</td>";
+ echo "<td>" . toImage('name / type') . "</td>";
+ echo "<td>" . toImage('geom') . "</td>";
+ echo "<td>" . toImage('search') . "</td>";
+ echo "<td>" . toImage('pos') . "</td>";
+ echo "<td>" . toImage('style_id') . "</td>";
+ echo "<td>" . toImage('upper') . "</td>";
+ echo "<td>" . toImage('label') . "</td>";
+ echo "<td>" . toImage('label_id') . "</td>";
+ echo "<td>" . toImage('show') . "</td>";
+ echo "<td>" . toImage('position') . "</td>";
+ echo "<td>" . toImage('mandatory') . "</td>";
+ echo "<td>" . toImage('edit') . "</td>";
+ echo "<td>" . toImage('html') . "</td>";
+ echo "<td>" . toImage('auth') . "</td>";
echo "</tr>";
$cnt = 0;
while($row = db_fetch_array($res)){
echo "<tr>";
- echo "<td><input type='text' size='4' name='f_id".$cnt."' value='".$row["f_id"]."' readonly></td>";
- echo "<td>".$row["element_name"]."</td>";
- echo "<td>".$row["element_type"]."</td>";
+ echo "<td><input type='text' size='1' name='f_id".$cnt."' value='".$row["f_id"]."' readonly></td>";
+ echo "<td>".$row["element_name"]."<br><div style='font-size:10'>(".$row["element_type"].")</div></td>";
echo "<td><input name='f_geom' type='radio' value='".$row["f_id"]."' ";
if($row["f_geom"] == 1){ echo " checked"; }
echo "></td>";
- echo "<td><input name='f_gid' type='radio' value='".$row["f_id"]."' ";
- if($row["f_gid"] == 1){ echo " checked"; }
- echo "></td>";
echo "<td><input name='f_search".$cnt."' type='checkbox'";
if($row["f_search"] == 1){ echo " checked"; }
echo "></td>";
- echo "<td><input name='f_pos".$cnt."' type='text' size='2' value='".$row["f_pos"]."'></td>";
+ echo "<td><input name='f_pos".$cnt."' type='text' size='1' value='".$row["f_pos"]."'></td>";
echo "<td><input name='f_style_id".$cnt."' type='text' size='2' value='".$row["f_style_id"]."'></td>";
echo "<td><input name='f_toupper".$cnt."' type='checkbox'";
if($row["f_toupper"] == 1){ echo " checked"; }
echo "></td>";
- echo "<td><input name='f_label".$cnt."' type='text' size='10' value='".$row["f_label"]."'></td>";
+ echo "<td><input name='f_label".$cnt."' type='text' size='4' value='".$row["f_label"]."'></td>";
echo "<td><input name='f_label_id".$cnt."' type='text' size='2' value='".$row["f_label_id"]."'></td>";
echo "<td><input name='f_show".$cnt."' type='checkbox'";
if($row["f_show"] == 1){ echo " checked"; }
echo "></td>";
- echo "<td><input name='f_respos".$cnt."' type='text' size='4' value='".$row["f_respos"]."'></td>";
+ echo "<td><input name='f_respos".$cnt."' type='text' size='1' value='".$row["f_respos"]."'></td>";
echo "<td><input name='f_mandatory".$cnt."' type='checkbox'";
if($row["f_mandatory"] == 1){ echo " checked"; }
echo "></td>";
@@ -240,6 +240,7 @@
if($row["f_edit"] == 1){ echo " checked"; }
echo "></td>";
echo "<td><textarea name='f_form_element_html".$cnt."' cols='15' rows='1' >".stripslashes($row["f_form_element_html"])."</textarea></td>";
+ echo "<td><input name='f_auth_varname".$cnt."' type='text' size='8' value='".$row["f_auth_varname"]."'></td>";
echo "</tr>";
$cnt++;
}
More information about the Mapbender_commits
mailing list