summaryrefslogtreecommitdiff
path: root/www-ssl/admin
diff options
context:
space:
mode:
authorMoritz helios Rudert <helios@planetcyborg.de>2011-06-01 12:13:39 +0200
committerMoritz helios Rudert <helios@planetcyborg.de>2011-06-01 12:13:39 +0200
commit75448045cfe70054c8f4bae1bcfaf9bb0f70d330 (patch)
tree6a4d3d35019cdf933c1816e8522dc5d2557f5238 /www-ssl/admin
parent12e0b0d809c29d435a247798d7318cc9835980ea (diff)
fixes
Diffstat (limited to 'www-ssl/admin')
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/EngelType.php290
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/Recentchanges.php14
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/UserPicture.php226
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/aktiv.php106
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/dbUpdateFromXLS.php406
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/debug.php42
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/dect.php86
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/dect_call.php2
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/faq.1.php2
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/faq.php362
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/free.php68
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/free_DECT.php68
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/group.php70
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/index.php8
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/news.php188
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/room.php320
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/schichtplan.1.php0
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/schichtplan.php620
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/schichtplan_druck.1.php0
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/schichtplan_druck.php148
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/shiftadd.php518
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/sprache.php198
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/tshirt.php30
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/user.php240
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userArrived.php38
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userChangeNormal.php226
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userChangeSecure.php178
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userDefaultSetting.php164
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userSaveNormal.php210
-rw-r--r--[-rwxr-xr-x]www-ssl/admin/userSaveSecure.php298
30 files changed, 2563 insertions, 2563 deletions
diff --git a/www-ssl/admin/EngelType.php b/www-ssl/admin/EngelType.php
index 6d640ae4..1aec80dc 100755..100644
--- a/www-ssl/admin/EngelType.php
+++ b/www-ssl/admin/EngelType.php
@@ -6,42 +6,42 @@ include("../../../camp2011/includes/funktion_db.php");
function runSQL( $SQL)
{
- global $con;
- // hier muesste das SQL ausgefuehrt werden...
- $Erg = mysql_query($SQL, $con);
- if ($Erg)
- {
- echo "&Auml;nderung wurde gesichert...<br>";
- echo "[$SQL]<br>";
- return 1;
- }
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)";
- echo "<br><br>".mysql_error( $con ). "<br>";
- echo "[$SQL]<br>";
- return 0;
- }
+ global $con;
+ // hier muesste das SQL ausgefuehrt werden...
+ $Erg = mysql_query($SQL, $con);
+ if ($Erg)
+ {
+ echo "&Auml;nderung wurde gesichert...<br />";
+ echo "[$SQL]<br />";
+ return 1;
+ }
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)";
+ echo "<br /><br />".mysql_error( $con ). "<br />";
+ echo "[$SQL]<br />";
+ return 0;
+ }
}
function runSQL_log( $SQL, $commed)
{
- global $con;
- // hier muesste das SQL ausgefuehrt werden...
- $Erg = db_query($SQL, $commed);
- if ($Erg)
- {
- echo "&Auml;nderung wurde gesichert...<br>";
- echo "[$SQL]<br>";
- return 1;
- }
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)";
- echo "<br><br>".mysql_error( $con ). "<br>";
- echo "[$SQL]<br>";
- return 0;
- }
+ global $con;
+ // hier muesste das SQL ausgefuehrt werden...
+ $Erg = db_query($SQL, $commed);
+ if ($Erg)
+ {
+ echo "&Auml;nderung wurde gesichert...<br />";
+ echo "[$SQL]<br />";
+ return 1;
+ }
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)";
+ echo "<br /><br />".mysql_error( $con ). "<br />";
+ echo "[$SQL]<br />";
+ return 0;
+ }
}
@@ -51,33 +51,33 @@ $Erg = mysql_query($Sql, $con);
if( !IsSet($_GET["action"]) )
{
- echo "Hallo ".$_SESSION['Nick'].
- ",<br>\nhier hast du die M&ouml;glichkeit, neue Engeltypen f&uuml;r die Schichtpl&auml;ne einzutragen ".
- "oder vorhandene abzu&auml;ndern:<br><br>\n";
-
- echo "<a href=\"./EngelType.php?action=new\">- Neuen EngelType eintragen</a><br>\n";
-
- echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
- echo "<tr class=\"contenttopic\">\n";
-
- for( $i = 1; $i < mysql_num_fields($Erg); $i++ )
- {
- echo "\t<td>". mysql_field_name($Erg, $i). "</td>";
- }
- echo "\t<td>&Auml;ndern</td>";
- echo "</tr>";
-
- for( $t = 0; $t < mysql_num_rows($Erg); $t++ )
- {
- echo "\t<tr class=\"content\">\n";
- for ($j = 1; $j < mysql_num_fields($Erg); $j++)
- {
- echo "\t\t<td>".mysql_result($Erg, $t, $j)."</td>\n";
- }
- echo "\t\t<td><a href=\"./EngelType.php?action=change&TID=".mysql_result($Erg, $t, "TID")."\">###</a></td>\n";
- echo "\t</tr>\n";
- } // ende Auflistung Raeume
- echo "</table>";
+ echo "Hallo ".$_SESSION['Nick'].
+ ",<br />\nhier hast du die M&ouml;glichkeit, neue Engeltypen f&uuml;r die Schichtpl&auml;ne einzutragen ".
+ "oder vorhandene abzu&auml;ndern:<br /><br />\n";
+
+ echo "<a href=\"./EngelType.php?action=new\">- Neuen EngelType eintragen</a><br />\n";
+
+ echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
+ echo "<tr class=\"contenttopic\">\n";
+
+ for( $i = 1; $i < mysql_num_fields($Erg); $i++ )
+ {
+ echo "\t<td>". mysql_field_name($Erg, $i). "</td>";
+ }
+ echo "\t<td>&Auml;ndern</td>";
+ echo "</tr>";
+
+ for( $t = 0; $t < mysql_num_rows($Erg); $t++ )
+ {
+ echo "\t<tr class=\"content\">\n";
+ for ($j = 1; $j < mysql_num_fields($Erg); $j++)
+ {
+ echo "\t\t<td>".mysql_result($Erg, $t, $j)."</td>\n";
+ }
+ echo "\t\t<td><a href=\"./EngelType.php?action=change&TID=".mysql_result($Erg, $t, "TID")."\">###</a></td>\n";
+ echo "\t</tr>\n";
+ } // ende Auflistung Raeume
+ echo "</table>";
}
else
{
@@ -85,105 +85,105 @@ else
switch ($_GET["action"]) {
case 'new':
- echo "Neuen EngelType einrichten: <br>";
- echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
- echo "<table>\n";
-
- for( $Uj = 1; $Uj < mysql_num_fields($Erg); $Uj++ )
- {
- echo "<td>".mysql_field_name($Erg, $Uj)."</td>".
- "<td><input type=\"text\" size=\"40\" name=\"".mysql_field_name($Erg, $Uj)."\"></td></tr>\n";
- }
- echo "</table>\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"newsave\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
- break;
+ echo "Neuen EngelType einrichten: <br />";
+ echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
+ echo "<table>\n";
+
+ for( $Uj = 1; $Uj < mysql_num_fields($Erg); $Uj++ )
+ {
+ echo "<td>".mysql_field_name($Erg, $Uj)."</td>".
+ "<td><input type=\"text\" size=\"40\" name=\"".mysql_field_name($Erg, $Uj)."\"></td></tr>\n";
+ }
+ echo "</table>\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"newsave\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
+ break;
case 'newsave':
- $vars = $_GET;
- $count = count($vars) - 1;
- $vars = array_splice($vars, 0, $count);
- $Keys="";
- $Values="";
- foreach($vars as $key => $value){
- $Keys .= ", `$key`";
- $Values .= ", '$value'";
- }
-
- if( runSQL_log( "INSERT INTO `EngelType` (". substr($Keys, 2). ") VALUES (". substr($Values, 2). ")",
- "save new EngelType") )
- {
- SetHeaderGo2Back();
-
- $SQL2 = "SELECT * FROM `EngelType` WHERE `Name`='". $_GET["Name"]. "'";
- $ERG = mysql_query($SQL2, $con);
-
- if( mysql_num_rows($ERG) == 1)
- runSQL_log( "ALTER TABLE `Room` ADD `DEFAULT_EID_". mysql_result( $ERG, 0, 0).
- "` INT DEFAULT '0' NOT NULL;",
- "add new EngelType in Romm Table");
- }
- break;
+ $vars = $_GET;
+ $count = count($vars) - 1;
+ $vars = array_splice($vars, 0, $count);
+ $Keys="";
+ $Values="";
+ foreach($vars as $key => $value){
+ $Keys .= ", `$key`";
+ $Values .= ", '$value'";
+ }
+
+ if( runSQL_log( "INSERT INTO `EngelType` (". substr($Keys, 2). ") VALUES (". substr($Values, 2). ")",
+ "save new EngelType") )
+ {
+ SetHeaderGo2Back();
+
+ $SQL2 = "SELECT * FROM `EngelType` WHERE `Name`='". $_GET["Name"]. "'";
+ $ERG = mysql_query($SQL2, $con);
+
+ if( mysql_num_rows($ERG) == 1)
+ runSQL_log( "ALTER TABLE `Room` ADD `DEFAULT_EID_". mysql_result( $ERG, 0, 0).
+ "` INT DEFAULT '0' NOT NULL;",
+ "add new EngelType in Romm Table");
+ }
+ break;
case 'change':
- if (! IsSet($_GET["TID"]))
- echo "Fehlerhafter Aufruf!";
- else
- {
- echo "Raum ab&auml;ndern:\n";
- echo "Hier kannst du eintragen, den EngelType &auml;ndern.";
- echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
- echo "<table>\n";
-
- $SQL2 = "SELECT * FROM `EngelType` WHERE `TID`='". $_GET["TID"]. "'";
- $ERG = mysql_query($SQL2, $con);
+ if (! IsSet($_GET["TID"]))
+ echo "Fehlerhafter Aufruf!";
+ else
+ {
+ echo "Raum ab&auml;ndern:\n";
+ echo "Hier kannst du eintragen, den EngelType &auml;ndern.";
+ echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
+ echo "<table>\n";
+
+ $SQL2 = "SELECT * FROM `EngelType` WHERE `TID`='". $_GET["TID"]. "'";
+ $ERG = mysql_query($SQL2, $con);
- for ($Uj = 1; $Uj < mysql_num_fields($ERG); $Uj++)
- echo "<tr><td>". mysql_field_name($ERG, $Uj). "</td>".
- "<td><input type=\"text\" size=\"40\" name=\"e". mysql_field_name($ERG, $Uj). "\" ".
- "value=\"". mysql_result($ERG, 0, $Uj). "\"></td></tr>\n";
-
- echo "</table>\n";
- echo "<input type=\"hidden\" name=\"eTID\" value=\"". $_GET["TID"]. "\">\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"changesave\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
- echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
- echo "<input type=\"hidden\" name=\"TID\" value=\"". $_GET["TID"]. "\">\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"delete\">\n";
- echo "<input type=\"submit\" value=\"L&ouml;schen...\">";
- echo "</form>";
- }
- break;
-
+ for ($Uj = 1; $Uj < mysql_num_fields($ERG); $Uj++)
+ echo "<tr><td>". mysql_field_name($ERG, $Uj). "</td>".
+ "<td><input type=\"text\" size=\"40\" name=\"e". mysql_field_name($ERG, $Uj). "\" ".
+ "value=\"". mysql_result($ERG, 0, $Uj). "\"></td></tr>\n";
+
+ echo "</table>\n";
+ echo "<input type=\"hidden\" name=\"eTID\" value=\"". $_GET["TID"]. "\">\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"changesave\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
+ echo "<form action=\"./EngelType.php\" method=\"GET\">\n";
+ echo "<input type=\"hidden\" name=\"TID\" value=\"". $_GET["TID"]. "\">\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"delete\">\n";
+ echo "<input type=\"submit\" value=\"L&ouml;schen...\">";
+ echo "</form>";
+ }
+ break;
+
case 'changesave':
$vars = $_GET;
$count = count($vars) - 2;
$vars = array_splice($vars, 0, $count);
- $keys="";
- $sql="";
+ $keys="";
+ $sql="";
foreach($vars as $key => $value)
- {
- $keys = substr( $key, 1);
- $sql .= ", `". $keys. "`='". $value. "'";
+ {
+ $keys = substr( $key, 1);
+ $sql .= ", `". $keys. "`='". $value. "'";
}
- runSQL_log( "UPDATE `EngelType` SET ". substr($sql, 2). " WHERE `TID`='". $_GET["eTID"]. "'",
- "Save Change EngelType");
- SetHeaderGo2Back();
- break;
+ runSQL_log( "UPDATE `EngelType` SET ". substr($sql, 2). " WHERE `TID`='". $_GET["eTID"]. "'",
+ "Save Change EngelType");
+ SetHeaderGo2Back();
+ break;
case 'delete':
- if (IsSet($_GET["TID"]))
- {
- if( runSQL_log( "DELETE FROM `EngelType` WHERE `TID`='". $_GET["TID"]. "'", "delete EngelType"))
- runSQL_log( "ALTER TABLE `Room` DROP `DEFAULT_EID_". $_GET["TID"]. "`;",
- "delete EngelType in Room Table");
- }
- else
- echo "Fehlerhafter Aufruf";
- SetHeaderGo2Back();
- break;
+ if (IsSet($_GET["TID"]))
+ {
+ if( runSQL_log( "DELETE FROM `EngelType` WHERE `TID`='". $_GET["TID"]. "'", "delete EngelType"))
+ runSQL_log( "ALTER TABLE `Room` DROP `DEFAULT_EID_". $_GET["TID"]. "`;",
+ "delete EngelType in Room Table");
+ }
+ else
+ echo "Fehlerhafter Aufruf";
+ SetHeaderGo2Back();
+ break;
}
}
diff --git a/www-ssl/admin/Recentchanges.php b/www-ssl/admin/Recentchanges.php
index 38c659dd..6bb8f59d 100755..100644
--- a/www-ssl/admin/Recentchanges.php
+++ b/www-ssl/admin/Recentchanges.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "ChangeLog";
$header = "Datenbank-Auszug";
@@ -14,12 +14,12 @@ echo "<tr>\n\t<th>Time</th>\n\t<th>User</th>\n\t<th>Commend</th>\n\t<th>SQL Comm
for ($n = 0 ; $n < mysql_num_rows($Erg) ; $n++)
{
- echo "<tr>\n";
- echo "\t<td>". mysql_result( $Erg, $n, "Time"). "</td>\n";
- echo "\t<td>". UID2Nick(mysql_result( $Erg, $n, "UID")). displayavatar(mysql_result( $Erg, $n, "UID")). "</td>\n";
- echo "\t<td>". mysql_result( $Erg, $n, "Commend"). "</td>\n";
- echo "\t<td>". mysql_result( $Erg, $n, "SQLCommad"). "</td>\n";
- echo "</tr>\n";
+ echo "<tr>\n";
+ echo "\t<td>". mysql_result( $Erg, $n, "Time"). "</td>\n";
+ echo "\t<td>". UID2Nick(mysql_result( $Erg, $n, "UID")). displayavatar(mysql_result( $Erg, $n, "UID")). "</td>\n";
+ echo "\t<td>". mysql_result( $Erg, $n, "Commend"). "</td>\n";
+ echo "\t<td>". mysql_result( $Erg, $n, "SQLCommad"). "</td>\n";
+ echo "</tr>\n";
}
echo "</table>\n";
diff --git a/www-ssl/admin/UserPicture.php b/www-ssl/admin/UserPicture.php
index 93e75bf1..00716329 100755..100644
--- a/www-ssl/admin/UserPicture.php
+++ b/www-ssl/admin/UserPicture.php
@@ -7,114 +7,114 @@ include ("../../../camp2011/includes/funktion_schichtplan_aray.php");
if( IsSet($_GET["action"]) )
{
- UnSet($SQL);
+ UnSet($SQL);
- switch ($_GET["action"])
- {
- case 'FormUpload':
- echo "Hier kannst Du ein Foto hochladen f&ouml;r:";
- echo "<form action=\"./UserPicture.php?action=sendPicture\" method=\"post\" enctype=\"multipart/form-data\">\n";
- echo "\t<select name=\"UID\">\n";
- $usql="SELECT * FROM `User` ORDER BY `Nick`";
- $uErg = mysql_query($usql, $con);
- for ($k=0; $k<mysql_num_rows($uErg); $k++)
- echo "\t\t<option value=\"".mysql_result($uErg, $k, "UID")."\">". mysql_result($uErg, $k, "Nick"). "</option>\n";
- echo "\t</select>\n";
- echo "\t<input type=\"hidden\" name=\"action\" value=\"sendPicture\">\n";
- echo "\t<input name=\"file\" type=\"file\" size=\"50\" maxlength=\"". get_cfg_var("post_max_size"). "\">\n";
- echo "\t(max ". get_cfg_var("post_max_size"). "Byte)<br>\n";
- echo "\t<input type=\"submit\" value=\"". Get_Text("upload"),"\">\n";
- echo "</form>\n";
- break;
- case 'sendPicture':
- if( ($_FILES["file"]["size"] > 0) && (isset( $_POST["UID"])) )
- {
- if( ($_FILES["file"]["type"] == "image/jpeg") ||
- ($_FILES["file"]["type"] == "image/png") ||
- ($_FILES["file"]["type"] == "image/gif") )
- {
- $data = addslashes(fread(fopen($_FILES["file"]["tmp_name"], "r"), filesize($_FILES["file"]["tmp_name"])));
+ switch ($_GET["action"])
+ {
+ case 'FormUpload':
+ echo "Hier kannst Du ein Foto hochladen f&ouml;r:";
+ echo "<form action=\"./UserPicture.php?action=sendPicture\" method=\"post\" enctype=\"multipart/form-data\">\n";
+ echo "\t<select name=\"UID\">\n";
+ $usql="SELECT * FROM `User` ORDER BY `Nick`";
+ $uErg = mysql_query($usql, $con);
+ for ($k=0; $k<mysql_num_rows($uErg); $k++)
+ echo "\t\t<option value=\"".mysql_result($uErg, $k, "UID")."\">". mysql_result($uErg, $k, "Nick"). "</option>\n";
+ echo "\t</select>\n";
+ echo "\t<input type=\"hidden\" name=\"action\" value=\"sendPicture\">\n";
+ echo "\t<input name=\"file\" type=\"file\" size=\"50\" maxlength=\"". get_cfg_var("post_max_size"). "\">\n";
+ echo "\t(max ". get_cfg_var("post_max_size"). "Byte)<br />\n";
+ echo "\t<input type=\"submit\" value=\"". Get_Text("upload"),"\">\n";
+ echo "</form>\n";
+ break;
+ case 'sendPicture':
+ if( ($_FILES["file"]["size"] > 0) && (isset( $_POST["UID"])) )
+ {
+ if( ($_FILES["file"]["type"] == "image/jpeg") ||
+ ($_FILES["file"]["type"] == "image/png") ||
+ ($_FILES["file"]["type"] == "image/gif") )
+ {
+ $data = addslashes(fread(fopen($_FILES["file"]["tmp_name"], "r"), filesize($_FILES["file"]["tmp_name"])));
- if( GetPicturShow( $_POST['UID']) == "")
- $SQL = "INSERT INTO `UserPicture` ".
- "( `UID`,`Bild`, `ContentType`, `show`) ".
- "VALUES ('". $_POST['UID']. "', '$data', '". $_FILES["file"]["type"]. "', 'N')";
- else
- $SQL = "UPDATE `UserPicture` SET ".
- "`Bild`='$data', ".
- "`ContentType`='". $_FILES["file"]["type"]. "' ".
- "WHERE `UID`='". $_POST['UID']. "'";
+ if( GetPicturShow( $_POST['UID']) == "")
+ $SQL = "INSERT INTO `UserPicture` ".
+ "( `UID`,`Bild`, `ContentType`, `show`) ".
+ "VALUES ('". $_POST['UID']. "', '$data', '". $_FILES["file"]["type"]. "', 'N')";
+ else
+ $SQL = "UPDATE `UserPicture` SET ".
+ "`Bild`='$data', ".
+ "`ContentType`='". $_FILES["file"]["type"]. "' ".
+ "WHERE `UID`='". $_POST['UID']. "'";
- echo "Upload Pictur:'" . $_FILES["file"]["name"] . "', ".
- "MIME-Type: " . $_FILES["file"]["type"]. ", ".
- $_FILES["file"]["size"]. " Byte ".
- "for ". UID2Nick( $_POST["UID"]);
- }
- else
- Print_Text("pub_einstellungen_send_KO");
- }
- else
- Print_Text("pub_einstellungen_send_KO");
- break;
+ echo "Upload Pictur:'" . $_FILES["file"]["name"] . "', ".
+ "MIME-Type: " . $_FILES["file"]["type"]. ", ".
+ $_FILES["file"]["size"]. " Byte ".
+ "for ". UID2Nick( $_POST["UID"]);
+ }
+ else
+ Print_Text("pub_einstellungen_send_KO");
+ }
+ else
+ Print_Text("pub_einstellungen_send_KO");
+ break;
- case 'SetN':
- if (IsSet($_GET["UID"]))
- {
- echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde gesperrt:<br>";
- $SQL = "UPDATE `UserPicture` SET `show`='N' WHERE `UID`='". $_GET["UID"]. "'";
- }
- else
- echo "Fehlerhafter Aufruf";
- break;
- case 'SetY':
- if (IsSet($_GET["UID"]))
- {
- echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde Freigegeben:<br>";
- $SQL = "UPDATE `UserPicture` SET `show`='Y' WHERE `UID`='". $_GET["UID"]. "'";
- }
- else
- echo "Fehlerhafter Aufruf";
- break;
- case 'del':
- echo "Wollen Sie das Bild von '". UID2Nick( $_GET["UID"]). "' wirklich l&ouml;schen? ".
- "<a href=\"./UserPicture.php?action=delYes&UID=". $_GET["UID"]. "\">Yes</a>";
- break;
- case 'delYes':
- if (IsSet($_GET["UID"]))
- {
- echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde gel&ouml;scht:<br>";
- $SQL = "DELETE FROM `UserPicture` WHERE `UID`='". $_GET["UID"]. "' LIMIT 1";
- }
- else
- echo "Fehlerhafter Aufruf";
- break;
- default:
- echo "Fehlerhafter Aufruf";
-
- } //switch
+ case 'SetN':
+ if (IsSet($_GET["UID"]))
+ {
+ echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde gesperrt:<br />";
+ $SQL = "UPDATE `UserPicture` SET `show`='N' WHERE `UID`='". $_GET["UID"]. "'";
+ }
+ else
+ echo "Fehlerhafter Aufruf";
+ break;
+ case 'SetY':
+ if (IsSet($_GET["UID"]))
+ {
+ echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde Freigegeben:<br />";
+ $SQL = "UPDATE `UserPicture` SET `show`='Y' WHERE `UID`='". $_GET["UID"]. "'";
+ }
+ else
+ echo "Fehlerhafter Aufruf";
+ break;
+ case 'del':
+ echo "Wollen Sie das Bild von '". UID2Nick( $_GET["UID"]). "' wirklich l&ouml;schen? ".
+ "<a href=\"./UserPicture.php?action=delYes&UID=". $_GET["UID"]. "\">Yes</a>";
+ break;
+ case 'delYes':
+ if (IsSet($_GET["UID"]))
+ {
+ echo "Bild von '". UID2Nick( $_GET["UID"]). "' wurde gel&ouml;scht:<br />";
+ $SQL = "DELETE FROM `UserPicture` WHERE `UID`='". $_GET["UID"]. "' LIMIT 1";
+ }
+ else
+ echo "Fehlerhafter Aufruf";
+ break;
+ default:
+ echo "Fehlerhafter Aufruf";
+
+ } //switch
- // Update ???
- if (IsSet($SQL))
- {
- // hier muesste das SQL ausgefuehrt werden...
- $Erg = mysql_query($SQL, $con);
- if ($Erg == 1)
- echo "&Auml;nderung wurde gesichert...<br>";
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)";
- echo "<br><br>".mysql_error( $con ). "<br>($SQL)<br>";
- }
- } // Ende Update
- echo "<br>\n<hr width=\"100%\">\n<br>\n\n";
+ // Update ???
+ if (IsSet($SQL))
+ {
+ // hier muesste das SQL ausgefuehrt werden...
+ $Erg = mysql_query($SQL, $con);
+ if ($Erg == 1)
+ echo "&Auml;nderung wurde gesichert...<br />";
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)";
+ echo "<br /><br />".mysql_error( $con ). "<br />($SQL)<br />";
+ }
+ } // Ende Update
+ echo "<br />\n<hr width=\"100%\">\n<br />\n\n";
} //IF IsSet($action)
//ausgabe der Liste
$Sql = "SELECT * FROM `UserPicture` WHERE `UID`>0;";
$Erg = mysql_query($Sql, $con);
-
-echo "Hallo ". $_SESSION['Nick']. ",<br>\nhier hast du die M&ouml;glichkeit, die Bilder der Engel freizugeben:<br><br>\n";
+
+echo "Hallo ". $_SESSION['Nick']. ",<br />\nhier hast du die M&ouml;glichkeit, die Bilder der Engel freizugeben:<br /><br />\n";
echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
echo "<tr class=\"contenttopic\">\n";
@@ -125,25 +125,25 @@ echo "\t<td>L&ouml;schen</td>\n";
echo "</tr>";
for( $t = 0; $t < mysql_num_rows($Erg); $t++ )
-{
- $UIDs = mysql_result($Erg, $t, "UID");
- echo "\t<tr class=\"content\">\n";
-
- echo "\t\t<td>". UID2Nick(mysql_result($Erg, $t, "UID")). "</td>\n";
- echo "\t\t<td>". displayPictur( $UIDs, 0). "</td>\n";
-
- if( GetPicturShow( $UIDs) == "Y")
- echo "\t\t<td><a href=\"./UserPicture.php?action=SetN&UID=$UIDs\">sperren</a></td>\n";
- elseif( GetPicturShow( $UIDs) == "N")
- echo "\t\t<td><a href=\"./UserPicture.php?action=SetY&UID=$UIDs\">freigeben</a></td>\n";
- else
- echo "\t\t<td>ERROR: show='". GetPicturShow( $UIDs). "'</td>\n";
- echo "\t\t<td><a href=\"./UserPicture.php?action=del&UID=$UIDs\">del</a></td>\n";
- echo "\t</tr>\n";
+{
+ $UIDs = mysql_result($Erg, $t, "UID");
+ echo "\t<tr class=\"content\">\n";
+
+ echo "\t\t<td>". UID2Nick(mysql_result($Erg, $t, "UID")). "</td>\n";
+ echo "\t\t<td>". displayPictur( $UIDs, 0). "</td>\n";
+
+ if( GetPicturShow( $UIDs) == "Y")
+ echo "\t\t<td><a href=\"./UserPicture.php?action=SetN&UID=$UIDs\">sperren</a></td>\n";
+ elseif( GetPicturShow( $UIDs) == "N")
+ echo "\t\t<td><a href=\"./UserPicture.php?action=SetY&UID=$UIDs\">freigeben</a></td>\n";
+ else
+ echo "\t\t<td>ERROR: show='". GetPicturShow( $UIDs). "'</td>\n";
+ echo "\t\t<td><a href=\"./UserPicture.php?action=del&UID=$UIDs\">del</a></td>\n";
+ echo "\t</tr>\n";
} // ende Auflistung Raeume
echo "</table>";
-echo "<br><a href=\"./UserPicture.php?action=FormUpload\">picture upload</a>\n";
+echo "<br /><a href=\"./UserPicture.php?action=FormUpload\">picture upload</a>\n";
include ("../../../camp2011/includes/footer.php");
?>
diff --git a/www-ssl/admin/aktiv.php b/www-ssl/admin/aktiv.php
index f5e8c9c3..68199cfa 100755..100644
--- a/www-ssl/admin/aktiv.php
+++ b/www-ssl/admin/aktiv.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "akive Engel";
$header = "Liste der aktiven Engel";
@@ -6,38 +6,38 @@ include ("../../../camp2011/includes/header.php");
include ("../../../camp2011/includes/funktion_db_list.php");
echo "<form action=\"./aktiv.php\" method=\"post\">";
-echo Get_Text("pub_aktive_Text1")."<br>\n";
-echo Get_Text("pub_aktive_Text2")."<br><br>\n";
-
+echo Get_Text("pub_aktive_Text1")."<br />\n";
+echo Get_Text("pub_aktive_Text2")."<br /><br />\n";
+
// auswahlbox
echo Get_Text("pub_aktive_Text31")."\n";
echo "<select name=\"Anzahl\">\n";
for( $i=0; $i<50; $i++)
- echo "\t<option value=\"$i\">$i</option>\n";
+ echo "\t<option value=\"$i\">$i</option>\n";
echo "</select>";
-echo Get_Text("pub_aktive_Text32")."<br><br>\n";
+echo Get_Text("pub_aktive_Text32")."<br /><br />\n";
echo "<input type=\"submit\" name=\"SendType\" value=\"Show..\">\n";
echo "<input type=\"submit\" name=\"SendType\" value=\"Write..\">\n";
echo "</form>\n";
echo "<form action=\"./aktiv.php\" method=\"post\">\n";
- echo "\t<br><input type=\"submit\" name=\"ResetActive\" value=\"reset Active setting\">\n";
+ echo "\t<br /><input type=\"submit\" name=\"ResetActive\" value=\"reset Active setting\">\n";
echo "</form>\n";
if( Isset($_POST["ResetActive"]) )
{
- $SQLreset = "UPDATE `User` SET `Aktiv`='0'";
- $ErgReset = db_query($SQLreset, "Reset Active");
- if ($ErgReset != 1)
- echo "Fehler beim zuruecksetzen der Activ\n";
- else
- echo "Active wurde erfolgreich zurueckgesetzt\n";
+ $SQLreset = "UPDATE `User` SET `Aktiv`='0'";
+ $ErgReset = db_query($SQLreset, "Reset Active");
+ if ($ErgReset != 1)
+ echo "Fehler beim zuruecksetzen der Activ\n";
+ else
+ echo "Active wurde erfolgreich zurueckgesetzt\n";
}
if( IsSet($_POST["Anzahl"]) )
- echo "<br>\n\n".Get_Text("pub_aktive_Text5_1"). $_POST["Anzahl"]. Get_Text("pub_aktive_Text5_2"). ":";
+ echo "<br />\n\n".Get_Text("pub_aktive_Text5_1"). $_POST["Anzahl"]. Get_Text("pub_aktive_Text5_2"). ":";
-echo "<br><br>\n\n";
+echo "<br /><br />\n\n";
//ausgabe tabelle
echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
@@ -51,15 +51,15 @@ echo "\t<td>Freeloader ". Get_Text("pub_aktive_Time"). "</td>\n";
echo "\t<td>". Get_Text("pub_aktive_Time"). " result</td>\n";
echo "\t<td>". Get_Text("pub_aktive_Active"). "</td>\n";
echo "</tr>\n";
-
+
$SQL = "
SELECT d.UID, d.nr, d.len, d.lenWeight, f.nr AS nrFree, f.len AS lenFree, d.lenWeight - COALESCE(f.len, 0) as lenReal
- FROM
- (SELECT e.UID, COUNT(s.Len) as nr, SUM(s.Len) as len, SUM( s.Len*(1+(((HOUR(s.DateS)+2)%24)<10 and ((HOUR(s.DateE)+2)%24)<=10)) ) as lenWeight FROM `Shifts` AS s INNER JOIN `ShiftEntry` AS e USING(SID) WHERE NOT UID=0 GROUP BY UID) as d
- LEFT JOIN
- (SELECT UID, COUNT(Length) AS nr, SUM(Length) AS len FROM `ShiftFreeloader` GROUP BY UID) AS f
- USING(UID)
- ORDER BY lenReal DESC, nr DESC, UID";
+ FROM
+ (SELECT e.UID, COUNT(s.Len) as nr, SUM(s.Len) as len, SUM( s.Len*(1+(((HOUR(s.DateS)+2)%24)<10 and ((HOUR(s.DateE)+2)%24)<=10)) ) as lenWeight FROM `Shifts` AS s INNER JOIN `ShiftEntry` AS e USING(SID) WHERE NOT UID=0 GROUP BY UID) as d
+ LEFT JOIN
+ (SELECT UID, COUNT(Length) AS nr, SUM(Length) AS len FROM `ShiftFreeloader` GROUP BY UID) AS f
+ USING(UID)
+ ORDER BY lenReal DESC, nr DESC, UID";
$Erg = mysql_query($SQL, $con);
echo mysql_error($con);
@@ -68,42 +68,42 @@ $rowcount = mysql_num_rows($Erg);
$aktivecount=0;
for ($i=0; $i<$rowcount; $i++)
{
- echo "\n\n\t<tr class=\"content\">\n";
- echo "\t\t<td>". UID2Nick(mysql_result($Erg, $i, "UID")). "</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "nr"). "x</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "len"). "h</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "lenWeight"). "h</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "nrFree"). "x</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "lenFree"). "h</td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "lenReal"). "h</td>\n";
+ echo "\n\n\t<tr class=\"content\">\n";
+ echo "\t\t<td>". UID2Nick(mysql_result($Erg, $i, "UID")). "</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "nr"). "x</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "len"). "h</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "lenWeight"). "h</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "nrFree"). "x</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "lenFree"). "h</td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "lenReal"). "h</td>\n";
-
- echo "\t\t<td>";
- if (IsSet($_POST["Anzahl"]))
- {
- if( $_POST["Anzahl"] < mysql_result($Erg, $i, "lenReal") )
- {
- $aktivecount++;
- if( $_POST["SendType"]=="Show..")
- echo "show set";
- else
- {
- $SQL2="UPDATE `User` SET `Aktiv`='1' WHERE `UID`='". mysql_result($Erg, $i, "UID"). "' LIMIT 1";
- $Erg2 = db_query($SQL2, "update Active State");
- if ($Erg2 != 1)
- echo "Fehler beim speichern bei Engel ".UID2Nick(mysql_result($Erg, $i, "UID"));
- else
- echo "write set";
- }
- }
- }
- echo "</td>\n";
- echo "\t</tr>\n";
+
+ echo "\t\t<td>";
+ if (IsSet($_POST["Anzahl"]))
+ {
+ if( $_POST["Anzahl"] < mysql_result($Erg, $i, "lenReal") )
+ {
+ $aktivecount++;
+ if( $_POST["SendType"]=="Show..")
+ echo "show set";
+ else
+ {
+ $SQL2="UPDATE `User` SET `Aktiv`='1' WHERE `UID`='". mysql_result($Erg, $i, "UID"). "' LIMIT 1";
+ $Erg2 = db_query($SQL2, "update Active State");
+ if ($Erg2 != 1)
+ echo "Fehler beim speichern bei Engel ".UID2Nick(mysql_result($Erg, $i, "UID"));
+ else
+ echo "write set";
+ }
+ }
+ }
+ echo "</td>\n";
+ echo "\t</tr>\n";
} // ende Auflistung aktive Engel
echo "</table>";
-echo "<br>Anzahl eintraege: $aktivecount / $rowcount (Aktive/Mitschichten)<br><br>";
+echo "<br />Anzahl eintraege: $aktivecount / $rowcount (Aktive/Mitschichten)<br /><br />";
include ("../../../camp2011/includes/footer.php");
?>
diff --git a/www-ssl/admin/dbUpdateFromXLS.php b/www-ssl/admin/dbUpdateFromXLS.php
index 37612d7f..9a329355 100755..100644
--- a/www-ssl/admin/dbUpdateFromXLS.php
+++ b/www-ssl/admin/dbUpdateFromXLS.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "DB Update from XML";
$header = "DB Update from XML";
include ("../../../camp2011/includes/header.php");
@@ -16,213 +16,213 @@ $EnableSchudleDB = 1;
/*##############################################################################################
- erstellt Arrays der Reume
+ erstellt Arrays der Reume
##############################################################################################*/
function CreateRoomArrays()
{
- global $Room, $RoomID, $RoomName, $con;
+ global $Room, $RoomID, $RoomName, $con;
- $sql = "SELECT `RID`, `Name` FROM `Room` ".
- "WHERE `Show`='Y'".
- "ORDER BY `Number`, `Name`;";
- $Erg = mysql_query($sql, $con);
- $rowcount = mysql_num_rows($Erg);
+ $sql = "SELECT `RID`, `Name` FROM `Room` ".
+ "WHERE `Show`='Y'".
+ "ORDER BY `Number`, `Name`;";
+ $Erg = mysql_query($sql, $con);
+ $rowcount = mysql_num_rows($Erg);
- for ($i=0; $i<$rowcount; $i++)
- {
- $Room[$i]["RID"] = mysql_result($Erg, $i, "RID");
- $Room[$i]["Name"] = mysql_result($Erg, $i, "Name");
- $RoomID[ mysql_result($Erg, $i, "RID") ] = mysql_result($Erg, $i, "Name");
- $RoomName[ mysql_result($Erg, $i, "Name") ] = mysql_result($Erg, $i, "RID");
- }
+ for ($i=0; $i<$rowcount; $i++)
+ {
+ $Room[$i]["RID"] = mysql_result($Erg, $i, "RID");
+ $Room[$i]["Name"] = mysql_result($Erg, $i, "Name");
+ $RoomID[ mysql_result($Erg, $i, "RID") ] = mysql_result($Erg, $i, "Name");
+ $RoomName[ mysql_result($Erg, $i, "Name") ] = mysql_result($Erg, $i, "RID");
+ }
}
CreateRoomArrays();
/*##############################################################################################
- F I L E
+ F I L E
##############################################################################################*/
-echo "\n\n<br>\n<h1>XML File:</h1>\n";
+echo "\n\n<br />\n<h1>XML File:</h1>\n";
if( isset($_POST["PentabarfUser"]) && isset($_POST["password"]) && isset($_POST["PentabarfURL"]))
{
- echo "Update XCAL-File from Pentabarf..";
- if($PentabarfGetWith=="fsockopen")
- {
+ echo "Update XCAL-File from Pentabarf..";
+ if($PentabarfGetWith=="fsockopen")
+ {
- //backup error messeges and delate
- $Backuperror_messages = $error_messages;
- $fp = fsockopen( "ssl://$PentabarfXMLhost", 443, $errno, $errstr, 30);
-// $error_messages = $Backuperror_messages;
-
- if( !$fp)
- {
- echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!".
- "[$errstr ($errno)]</h2>";
- }
- else
- {
- if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
- {
- $head = 'GET /'. $PentabarfXMLpath. $_POST["PentabarfURL"]. ' HTTP/1.1'."\r\n".
- 'Host: '. $PentabarfXMLhost. "\r\n".
- 'User-Agent: Engelsystem'. "\r\n".
- 'Authorization: Basic '.
- base64_encode($_POST["PentabarfUser"]. ':'. $_POST["password"])."\r\n".
- "\r\n";
- fputs( $fp, $head);
- $Zeilen = -1;
- while (!feof($fp))
- {
- $Temp= fgets($fp,1024);
-
- // ende des headers
- if( $Temp== "f20\r\n" )
- {
- $Zeilen = 0;
- $Temp="";
- }
-
- //file ende?
- if( $Temp=="0\r\n")
- break;
+ //backup error messeges and delate
+ $Backuperror_messages = $error_messages;
+ $fp = fsockopen( "ssl://$PentabarfXMLhost", 443, $errno, $errstr, 30);
+// $error_messages = $Backuperror_messages;
+
+ if( !$fp)
+ {
+ echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!".
+ "[$errstr ($errno)]</h2>";
+ }
+ else
+ {
+ if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
+ {
+ $head = 'GET /'. $PentabarfXMLpath. $_POST["PentabarfURL"]. ' HTTP/1.1'."\r\n".
+ 'Host: '. $PentabarfXMLhost. "\r\n".
+ 'User-Agent: Engelsystem'. "\r\n".
+ 'Authorization: Basic '.
+ base64_encode($_POST["PentabarfUser"]. ':'. $_POST["password"])."\r\n".
+ "\r\n";
+ fputs( $fp, $head);
+ $Zeilen = -1;
+ while (!feof($fp))
+ {
+ $Temp= fgets($fp,1024);
+
+ // ende des headers
+ if( $Temp== "f20\r\n" )
+ {
+ $Zeilen = 0;
+ $Temp="";
+ }
+
+ //file ende?
+ if( $Temp=="0\r\n")
+ break;
- if( ($Zeilen>-1) && ($Temp!="ffb\r\n") )
- {
- //steuerzeichen ausfiltern
- if( strpos( "#$Temp", "\r\n") > 0)
- $Temp = substr($Temp, 0, strlen($Temp)-2);
- if( strpos( "#$Temp", "1005") > 0)
- $Temp = "";
- if( strpos( "#$Temp", "783") > 0)
- $Temp = "";
- //schreiben in file
- fputs( $fileOut, $Temp);
- $Zeilen++;
- }
- }
- fclose( $fileOut);
-
- echo "<br>Es wurden $Zeilen Zeilen eingelesen<br>";
- }
- else
- echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
- fclose($fp);
- }
- }
- elseif($PentabarfGetWith=="fopen")
- {
- //user uns password in url einbauen
- $FileNameIn = "https://". $_POST["PentabarfUser"]. ':'. $_POST["password"]. "@".
- $PentabarfXMLhost. "/". $PentabarfXMLpath. $_POST["PentabarfURL"];
+ if( ($Zeilen>-1) && ($Temp!="ffb\r\n") )
+ {
+ //steuerzeichen ausfiltern
+ if( strpos( "#$Temp", "\r\n") > 0)
+ $Temp = substr($Temp, 0, strlen($Temp)-2);
+ if( strpos( "#$Temp", "1005") > 0)
+ $Temp = "";
+ if( strpos( "#$Temp", "783") > 0)
+ $Temp = "";
+ //schreiben in file
+ fputs( $fileOut, $Temp);
+ $Zeilen++;
+ }
+ }
+ fclose( $fileOut);
+
+ echo "<br />Es wurden $Zeilen Zeilen eingelesen<br />";
+ }
+ else
+ echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
+ fclose($fp);
+ }
+ }
+ elseif($PentabarfGetWith=="fopen")
+ {
+ //user uns password in url einbauen
+ $FileNameIn = "https://". $_POST["PentabarfUser"]. ':'. $_POST["password"]. "@".
+ $PentabarfXMLhost. "/". $PentabarfXMLpath. $_POST["PentabarfURL"];
- if( ($fileIn = fopen( $FileNameIn, "r")) != FALSE)
- {
- if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
- {
- $Zeilen = 0;
- while (!feof($fileIn))
- {
- $Zeilen++;
- fputs( $fileOut, fgets( $fileIn));
- }
- fclose( $fileOut);
- echo "<br>Es wurden $Zeilen Zeilen eingelesen<br>";
- }
- else
- echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
- fclose( $fileIn);
- }
- else
- echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!</h2>";
- }
- elseif( $PentabarfGetWith=="wget")
- {
- $Command = "wget --http-user=". $_POST["PentabarfUser"]. " --http-passwd=".$_POST["password"]. " ".
- "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"].
- " --output-file=$Tempdir/engelXMLwgetLog --output-document=$Tempdir/engelXML".
- " --no-check-certificate";
- echo system( $Command, $Status);
- if( $Status==0)
- echo "OK.<br>";
- else
- echo "fail ($Status)($Command).<br>";
- }
- elseif( $PentabarfGetWith=="lynx")
- {
- $Command = "lynx -auth=". $_POST["PentabarfUser"]. ":".$_POST["password"]. " -dump ".
- "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. " > $Tempdir/engelXML";
- echo system( $Command, $Status);
- if( $Status==0)
- echo "OK.<br>";
- else
- echo "fail ($Status)($Command).<br>";
- }
- elseif($PentabarfGetWith=="fopen")
- {
- //user uns password in url einbauen
- $FileNameIn = "https://". $_POST["PentabarfUser"]. ':'. $_POST["password"]. "@".
- $PentabarfXMLhost. "/". $PentabarfXMLpath. $_POST["PentabarfURL"];
+ if( ($fileIn = fopen( $FileNameIn, "r")) != FALSE)
+ {
+ if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
+ {
+ $Zeilen = 0;
+ while (!feof($fileIn))
+ {
+ $Zeilen++;
+ fputs( $fileOut, fgets( $fileIn));
+ }
+ fclose( $fileOut);
+ echo "<br />Es wurden $Zeilen Zeilen eingelesen<br />";
+ }
+ else
+ echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
+ fclose( $fileIn);
+ }
+ else
+ echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!</h2>";
+ }
+ elseif( $PentabarfGetWith=="wget")
+ {
+ $Command = "wget --http-user=". $_POST["PentabarfUser"]. " --http-passwd=".$_POST["password"]. " ".
+ "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"].
+ " --output-file=$Tempdir/engelXMLwgetLog --output-document=$Tempdir/engelXML".
+ " --no-check-certificate";
+ echo system( $Command, $Status);
+ if( $Status==0)
+ echo "OK.<br />";
+ else
+ echo "fail ($Status)($Command).<br />";
+ }
+ elseif( $PentabarfGetWith=="lynx")
+ {
+ $Command = "lynx -auth=". $_POST["PentabarfUser"]. ":".$_POST["password"]. " -dump ".
+ "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. " > $Tempdir/engelXML";
+ echo system( $Command, $Status);
+ if( $Status==0)
+ echo "OK.<br />";
+ else
+ echo "fail ($Status)($Command).<br />";
+ }
+ elseif($PentabarfGetWith=="fopen")
+ {
+ //user uns password in url einbauen
+ $FileNameIn = "https://". $_POST["PentabarfUser"]. ':'. $_POST["password"]. "@".
+ $PentabarfXMLhost. "/". $PentabarfXMLpath. $_POST["PentabarfURL"];
- if( ($fileIn = fopen( $FileNameIn, "r")) != FALSE)
- {
- if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
- {
- $Zeilen = 0;
- while (!feof($fileIn))
- {
- $Zeilen++;
- fputs( $fileOut, fgets( $fileIn));
- }
- fclose( $fileOut);
- echo "<br>Es wurden $Zeilen Zeilen eingelesen<br>";
- }
- else
- echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
- fclose( $fileIn);
- }
- else
- echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!</h2>";
- }
- elseif( $PentabarfGetWith=="wget")
- {
- $Command = "wget --http-user=". $_POST["PentabarfUser"]. " --http-passwd=".$_POST["password"]. " ".
- "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"].
- " --output-file=$Tempdir/engelXMLwgetLog --output-document=$Tempdir/engelXML".
- " --no-check-certificate";
- echo system( $Command, $Status);
- if( $Status==0)
- echo "OK.<br>";
- else
- echo "fail ($Status)($Command).<br>";
- }
- elseif( $PentabarfGetWith=="lynx")
- {
- $Command = "lynx -auth=". $_POST["PentabarfUser"]. ":".$_POST["password"]. " -dump ".
- "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. " > $Tempdir/engelXML";
- echo system( $Command, $Status);
- if( $Status==0)
- echo "OK.<br>";
- else
- echo "fail ($Status)($Command).<br>";
- }
- else
- echo "<h1>The PentabarfGetWith='$PentabarfGetWith' not supported</h1>";
+ if( ($fileIn = fopen( $FileNameIn, "r")) != FALSE)
+ {
+ if( ($fileOut = fopen( "$Tempdir/engelXML", "w")) != FALSE)
+ {
+ $Zeilen = 0;
+ while (!feof($fileIn))
+ {
+ $Zeilen++;
+ fputs( $fileOut, fgets( $fileIn));
+ }
+ fclose( $fileOut);
+ echo "<br />Es wurden $Zeilen Zeilen eingelesen<br />";
+ }
+ else
+ echo "<h2>fail: File '$Tempdir/engelXML' not writeable!</h2>";
+ fclose( $fileIn);
+ }
+ else
+ echo "<h2>fail: File 'https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. "' not readable!</h2>";
+ }
+ elseif( $PentabarfGetWith=="wget")
+ {
+ $Command = "wget --http-user=". $_POST["PentabarfUser"]. " --http-passwd=".$_POST["password"]. " ".
+ "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"].
+ " --output-file=$Tempdir/engelXMLwgetLog --output-document=$Tempdir/engelXML".
+ " --no-check-certificate";
+ echo system( $Command, $Status);
+ if( $Status==0)
+ echo "OK.<br />";
+ else
+ echo "fail ($Status)($Command).<br />";
+ }
+ elseif( $PentabarfGetWith=="lynx")
+ {
+ $Command = "lynx -auth=". $_POST["PentabarfUser"]. ":".$_POST["password"]. " -dump ".
+ "https://$PentabarfXMLhost/$PentabarfXMLpath". $_POST["PentabarfURL"]. " > $Tempdir/engelXML";
+ echo system( $Command, $Status);
+ if( $Status==0)
+ echo "OK.<br />";
+ else
+ echo "fail ($Status)($Command).<br />";
+ }
+ else
+ echo "<h1>The PentabarfGetWith='$PentabarfGetWith' not supported</h1>";
}
else
{
- echo "<form action=\"dbUpdateFromXLS.php\" method=\"post\">\n";
- echo "<table border=\"0\">\n";
- echo "\t<tr><td>XCAL-File: https://$PentabarfXMLhost/$PentabarfXMLpath</td>".
- "<td><input name=\"PentabarfURL\" type=\"text\" size=\"4\" maxlength=\"5\" ".
- "value=\"$PentabarfXMLEventID\"></td></tr>\n";
- echo "\t<tr><td>Username:</td>".
- "<td><input name=\"PentabarfUser\" type=\"text\" size=\"30\" maxlength=\"30\"></td></tr>\n";
- echo "\t<tr><td>Password:</td>".
- "<td><input name=\"password\" type=\"password\" size=\"30\" maxlength=\"30\"></td></tr>\n";
- echo "\t<tr><td></td><td><input type=\"submit\" name=\"FileUpload\" value=\"upload\"></td></tr>\n";
- echo "</table>\n";
- echo "</form>\n";
+ echo "<form action=\"dbUpdateFromXLS.php\" method=\"post\">\n";
+ echo "<table border=\"0\">\n";
+ echo "\t<tr><td>XCAL-File: https://$PentabarfXMLhost/$PentabarfXMLpath</td>".
+ "<td><input name=\"PentabarfURL\" type=\"text\" size=\"4\" maxlength=\"5\" ".
+ "value=\"$PentabarfXMLEventID\"></td></tr>\n";
+ echo "\t<tr><td>Username:</td>".
+ "<td><input name=\"PentabarfUser\" type=\"text\" size=\"30\" maxlength=\"30\"></td></tr>\n";
+ echo "\t<tr><td>Password:</td>".
+ "<td><input name=\"password\" type=\"password\" size=\"30\" maxlength=\"30\"></td></tr>\n";
+ echo "\t<tr><td></td><td><input type=\"submit\" name=\"FileUpload\" value=\"upload\"></td></tr>\n";
+ echo "</table>\n";
+ echo "</form>\n";
}
@@ -235,52 +235,52 @@ $XMLmain = getXMLsubPease( $XMLmain, "VCALENDAR");
if( $ShowDataStrukture)
{
- echo "<pre><br>";
- echo $XMLmain->name;
- echo "<br>";
- print_r(array_values ($XMLmain->sub));
- echo "</pre>";
+ echo "<pre><br />";
+ echo $XMLmain->name;
+ echo "<br />";
+ print_r(array_values ($XMLmain->sub));
+ echo "</pre>";
}
/*
-echo "<br>";
+echo "<br />";
$Feld=7;
-echo "$Feld#". $XMLmain->sub[$Feld]->name. "<br>";
+echo "$Feld#". $XMLmain->sub[$Feld]->name. "<br />";
echo "$Feld#". $XMLmain->sub[$Feld]->sub;
//print_r(array_values ($XMLmain->sub[$Feld]->sub));
while(list($key, $value) = each($XMLmain->sub[$Feld]->sub))
- echo "?ID".$value->sub[1]->data. "=". $value->sub[2]->data. "\n";
+ echo "?ID".$value->sub[1]->data. "=". $value->sub[2]->data. "\n";
echo "</pre>";
*/
/*##############################################################################################
- V e r s i o n
+ V e r s i o n
##############################################################################################*/
echo "<hr>\n";
$XMLrelease = getXMLsubPease( $XMLmain, "X-WR-CALDESC");
-echo "release: ". $XMLrelease->data. "<br>\n";
+echo "release: ". $XMLrelease->data. "<br />\n";
//$XMLreleaseDate = getXMLsubPease( $XMLmain, "RELEASE-DATE");
-//echo "release date: ". $XMLreleaseDate->data. "<br>\n";
+//echo "release date: ". $XMLreleaseDate->data. "<br />\n";
echo "<hr>\n";
/*##############################################################################################
- V e r s i o n
+ V e r s i o n
##############################################################################################*/
if( $EnableRoomFunctions)
- include("../../../camp2011/includes/funktion_xml_room.php");
+ include("../../../camp2011/includes/funktion_xml_room.php");
if( $EnableSchudleFunctions)
- include("../../../camp2011/includes/funktion_xml_schudle.php");
+ include("../../../camp2011/includes/funktion_xml_schudle.php");
/*##############################################################################################
- U P D A T E A L L
+ U P D A T E A L L
##############################################################################################*/
-echo "\n\n<br>\n<h1>Update ALL:</h1>\n";
+echo "\n\n<br />\n<h1>Update ALL:</h1>\n";
echo "<form action=\"dbUpdateFromXLS.php\">\n";
echo "\t<input type=\"submit\" name=\"UpdateALL\" value=\"now\">\n";
diff --git a/www-ssl/admin/debug.php b/www-ssl/admin/debug.php
index b01a8a6c..b2c6357f 100755..100644
--- a/www-ssl/admin/debug.php
+++ b/www-ssl/admin/debug.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Debug-Liste";
$header = "Datenbank-Auszug";
@@ -9,22 +9,22 @@ echo "<h1>Web Counter</h1>";
funktion_db_list("Counter");
/*
-echo "<h1>Raeume</h1> <br>";
+echo "<h1>Raeume</h1> <br />";
funktion_db_list("Raeume");
-echo "<h1>Schichtbelegung</h1> <br>";
+echo "<h1>Schichtbelegung</h1> <br />";
funktion_db_list("Schichtbelegung");
-echo "<h1>Schichtplan</h1> <br>Hier findest du alle bisher eingetragenen Schichten:";
+echo "<h1>Schichtplan</h1> <br />Hier findest du alle bisher eingetragenen Schichten:";
funktion_db_list("Schichtplan");
-echo "<h1>User</h1> <br>";
+echo "<h1>User</h1> <br />";
funktion_db_list("User");
-echo "<h1>News</h1> <br>";
+echo "<h1>News</h1> <br />";
funktion_db_list("News");
-echo "<h1>FAQ</h1> <br>";
+echo "<h1>FAQ</h1> <br />";
funktion_db_list("FAQ");
echo "Deaktiviert";
@@ -32,34 +32,34 @@ echo "Deaktiviert";
echo "<hr>\n";
funktion_db_element_list_2row( "Tshirt-Size aller engel",
- "SELECT `Size`, COUNT(`Size`) FROM `User` GROUP BY `Size`");
-echo "<br>\n";
+ "SELECT `Size`, COUNT(`Size`) FROM `User` GROUP BY `Size`");
+echo "<br />\n";
funktion_db_element_list_2row( "Tshirt ausgegeben",
- "SELECT `Size`, COUNT(`Size`) FROM `User` WHERE `Tshirt`='1' GROUP BY `Size`");
-echo "<br>\n";
+ "SELECT `Size`, COUNT(`Size`) FROM `User` WHERE `Tshirt`='1' GROUP BY `Size`");
+echo "<br />\n";
funktion_db_element_list_2row( "Tshirt nicht ausgegeben (Gekommen=1)",
- "SELECT COUNT(`Size`), `Size` FROM `User` WHERE `Gekommen`='1' and `Tshirt`='0' GROUP BY `Size`");
+ "SELECT COUNT(`Size`), `Size` FROM `User` WHERE `Gekommen`='1' and `Tshirt`='0' GROUP BY `Size`");
echo "<hr>\n";
funktion_db_element_list_2row( "Hometown",
- "SELECT COUNT(`Hometown`), `Hometown` FROM `User` GROUP BY `Hometown`");
-echo "<br>\n";
+ "SELECT COUNT(`Hometown`), `Hometown` FROM `User` GROUP BY `Hometown`");
+echo "<br />\n";
funktion_db_element_list_2row( "Engeltypen",
- "SELECT COUNT(`Art`), `Art` FROM `User` GROUP BY `Art`");
+ "SELECT COUNT(`Art`), `Art` FROM `User` GROUP BY `Art`");
echo "<hr>\n";
funktion_db_element_list_2row( "Gesamte Arbeit",
- "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID)");
-echo "<br>\n";
+ "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID)");
+echo "<br />\n";
funktion_db_element_list_2row( "Geleisteter Arbeit",
- "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (ShiftEntry.UID!=0)");
+ "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (ShiftEntry.UID!=0)");
echo "<hr>\n";
funktion_db_element_list_2row( "Gesamte Arbeit (Ohne Raum aufabau (RID=7)",
- "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (Shifts.RID!=7)");
-echo "<br>\n";
+ "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (Shifts.RID!=7)");
+echo "<br />\n";
funktion_db_element_list_2row( "Geleisteter Arbeit (Ohne Raum aufabau (RID=7)",
- "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (ShiftEntry.UID!=0) AND (Shifts.RID!=7)");
+ "SELECT COUNT(*) AS `Count [x]`, SUM(Shifts.Len) as `Sum [h]` from Shifts LEFT JOIN ShiftEntry USING(SID) WHERE (ShiftEntry.UID!=0) AND (Shifts.RID!=7)");
diff --git a/www-ssl/admin/dect.php b/www-ssl/admin/dect.php
index e6096d27..76409cc6 100755..100644
--- a/www-ssl/admin/dect.php
+++ b/www-ssl/admin/dect.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Engelsystem - DECT";
$header = "DECT send call";
@@ -13,56 +13,56 @@ if( !isset($_GET["custum"])) $_GET["custum"] = "";
if( $_GET["dial"]=="dial")
{
- if( $_GET["DECT"]=="")
- $Number = $_GET["custum"];
- else
- $Number = $_GET["DECT"];
-
- if( strlen( $_GET["timeh"])== 1)
- $_GET["timeh"] = "0". $_GET["timeh"];
-
- if( strlen( $_GET["timem"])== 1)
- $_GET["timem"] = "0". $_GET["timem"];
-
-// SetWackeup( $Number, $_GET["timeh"], $_GET["timem"]);
- DialNumberIAX($Number, $_GET["timeh"], $_GET["timem"],0);
+ if( $_GET["DECT"]=="")
+ $Number = $_GET["custum"];
+ else
+ $Number = $_GET["DECT"];
+
+ if( strlen( $_GET["timeh"])== 1)
+ $_GET["timeh"] = "0". $_GET["timeh"];
+
+ if( strlen( $_GET["timem"])== 1)
+ $_GET["timem"] = "0". $_GET["timem"];
+
+// SetWackeup( $Number, $_GET["timeh"], $_GET["timem"]);
+ DialNumberIAX($Number, $_GET["timeh"], $_GET["timem"],0);
- $_GET["custum"] = $Number;
+ $_GET["custum"] = $Number;
}
- echo "<form action=\"./dect.php\" method=\"GET\">\n";
- echo "<table>\n";
+ echo "<form action=\"./dect.php\" method=\"GET\">\n";
+ echo "<table>\n";
- echo "<tr><th>Number</th><th>h:m</th><th></th></tr>\n";
+ echo "<tr><th>Number</th><th>h:m</th><th></th></tr>\n";
- echo "<tr><td>\n";
- // Listet alle Nicks auf
- echo "<select name=\"DECT\">\n";
- echo "\t<option value=\"\">costum</option>\n";
+ echo "<tr><td>\n";
+ // Listet alle Nicks auf
+ echo "<select name=\"DECT\">\n";
+ echo "\t<option value=\"\">costum</option>\n";
- $usql="SELECT * FROM `User` WHERE NOT `DECT`='' ORDER BY `Nick`";
- $uErg = mysql_query($usql, $con);
- $urowcount = mysql_num_rows($uErg);
- for ($k=0; $k<$urowcount; $k++)
- {
- echo "\t<option value=\"".mysql_result($uErg, $k, "DECT")."\">".
- mysql_result($uErg, $k, "Nick").
- " (". mysql_result($uErg, $k, "DECT"). ")".
- "</option>\n";
- }
- echo "</select>\n";
-
- echo "<input type=\"text\" name=\"custum\" size=\"4\" maxlength=\"4\" value=\"". $_GET["custum"]. "\">\n";
- echo "</td>\n";
+ $usql="SELECT * FROM `User` WHERE NOT `DECT`='' ORDER BY `Nick`";
+ $uErg = mysql_query($usql, $con);
+ $urowcount = mysql_num_rows($uErg);
+ for ($k=0; $k<$urowcount; $k++)
+ {
+ echo "\t<option value=\"".mysql_result($uErg, $k, "DECT")."\">".
+ mysql_result($uErg, $k, "Nick").
+ " (". mysql_result($uErg, $k, "DECT"). ")".
+ "</option>\n";
+ }
+ echo "</select>\n";
+
+ echo "<input type=\"text\" name=\"custum\" size=\"4\" maxlength=\"4\" value=\"". $_GET["custum"]. "\">\n";
+ echo "</td>\n";
- echo "<td><input type=\"text\" name=\"timeh\" size=\"2\" maxlength=\"2\" value=\"". gmdate("H", time()+90+3600). "\">:";
- echo "<input type=\"text\" name=\"timem\" size=\"2\" maxlength=\"2\" value=\"". gmdate("i", time()+90+3600). "\"></td>\n";
- echo "<td><input type=\"submit\" name=\"dial\" value=\"dial\"></td>\n";
- echo "</tr>";
- echo "</table>\n";
-
- echo "</form>";
+ echo "<td><input type=\"text\" name=\"timeh\" size=\"2\" maxlength=\"2\" value=\"". gmdate("H", time()+90+3600). "\">:";
+ echo "<input type=\"text\" name=\"timem\" size=\"2\" maxlength=\"2\" value=\"". gmdate("i", time()+90+3600). "\"></td>\n";
+ echo "<td><input type=\"submit\" name=\"dial\" value=\"dial\"></td>\n";
+ echo "</tr>";
+ echo "</table>\n";
+
+ echo "</form>";
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/dect_call.php b/www-ssl/admin/dect_call.php
index c69efa17..58c7cfe1 100755..100644
--- a/www-ssl/admin/dect_call.php
+++ b/www-ssl/admin/dect_call.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
include ("../../../camp2011/includes/header.php");
diff --git a/www-ssl/admin/faq.1.php b/www-ssl/admin/faq.1.php
index 0951fcb6..04dda6aa 100755..100644
--- a/www-ssl/admin/faq.1.php
+++ b/www-ssl/admin/faq.1.php
@@ -1,6 +1,6 @@
<h4 class="menu"> Anfragen und FAQ </h4>
<li><a href="faq.php?quest=all">Alle Anfragen</a></li>
-<li><a href="faq.php?quest=open">Offene Anfragen (<?PHP echo noAnswer(); ?>)</a></li>
+<li><a href="faq.php?quest=open">Offene Anfragen (<?php echo noAnswer(); ?>)</a></li>
<li><a href="faq.php?quest=faq">FAQ-Liste editiern</a></li>
diff --git a/www-ssl/admin/faq.php b/www-ssl/admin/faq.php
index 645c08cd..217e9188 100755..100644
--- a/www-ssl/admin/faq.php
+++ b/www-ssl/admin/faq.php
@@ -22,119 +22,119 @@ switch ($_GET["quest"])
// *---------------------------------------------------------------------------
case "all":
- $SQL="SELECT * FROM `Questions` ORDER BY QID DESC";
+ $SQL="SELECT * FROM `Questions` ORDER BY QID DESC";
?>
- Alle Anfragen:<br>
+ Alle Anfragen:<br />
<table width="100%" class="border" cellpadding="2" cellspacing="1">
<tr class="contenttopic">
- <th>Frage</th>
- <th>Anfragender</th>
+ <th>Frage</th>
+ <th>Anfragender</th>
<th>Beantwortet?</th>
<th>Antwort</th>
<th>Antwort von</th>
- <th>change</th>
+ <th>change</th>
</tr>
-<?PHP
+<?php
$Erg = mysql_query($SQL, $con);
// anzahl zeilen
$Zeilen = mysql_num_rows($Erg);
for ($n = 0 ; $n < $Zeilen ; $n++) {
- echo "<tr class=\"content\">\n";
- echo "<td>".mysql_result($Erg, $n, "Question")."</td>\n";
- echo "<td>".UID2Nick(mysql_result($Erg, $n, "UID"))."</td>\n";
- echo "<td>";
- if (mysql_result($Erg, $n, "AID")>0)
- {
- echo "Ja</td>\n";
- echo "<td>".mysql_result($Erg, $n, "Answer")."</td>\n";
- echo "<td>".UID2Nick(mysql_result($Erg, $n, "AID"))."</td>\n";
- }
- else
- {
- echo "Nein</td>\n";
- echo "<td>&nbsp;</td>\n";
- echo "<td>&nbsp;</td>\n";
- }
- echo "<td><a href=\"faq.php?quest=edit&QID=".mysql_result($Erg, $n, "QID")."\">xxx</a></td>";
- echo "</tr>\n";
- }
- echo "</table>\n";
- break;
-
+ echo "<tr class=\"content\">\n";
+ echo "<td>".mysql_result($Erg, $n, "Question")."</td>\n";
+ echo "<td>".UID2Nick(mysql_result($Erg, $n, "UID"))."</td>\n";
+ echo "<td>";
+ if (mysql_result($Erg, $n, "AID")>0)
+ {
+ echo "Ja</td>\n";
+ echo "<td>".mysql_result($Erg, $n, "Answer")."</td>\n";
+ echo "<td>".UID2Nick(mysql_result($Erg, $n, "AID"))."</td>\n";
+ }
+ else
+ {
+ echo "Nein</td>\n";
+ echo "<td>&nbsp;</td>\n";
+ echo "<td>&nbsp;</td>\n";
+ }
+ echo "<td><a href=\"faq.php?quest=edit&QID=".mysql_result($Erg, $n, "QID")."\">xxx</a></td>";
+ echo "</tr>\n";
+ }
+ echo "</table>\n";
+ break;
+
case "open":
- $SQL="SELECT * FROM `Questions` WHERE `AID`='0' ORDER BY `QID` DESC";
- $quest_bearb=1; // Fragenliste anzeigen
- echo "\t\tOffene Anfragen:<br>\n";
- break;
-
+ $SQL="SELECT * FROM `Questions` WHERE `AID`='0' ORDER BY `QID` DESC";
+ $quest_bearb=1; // Fragenliste anzeigen
+ echo "\t\tOffene Anfragen:<br />\n";
+ break;
+
case "edit":
- if (!IsSet($_GET["QID"]))
- echo "\t\tFehlerhafter Aufruf...<br>Bitte die Bearbeitung nochmals beginnen :)\n";
- else
- {
- $SQL = "SELECT * FROM `Questions` WHERE `QID`='". $_GET["QID"]. "'";
- $Erg = mysql_query($SQL, $con);
- echo "\t\t<form action=\"./faq.php\" method=\"GET\">\n";
- echo "\t\tAnfrage von <b>". UID2NICK(mysql_result($Erg, 0, "UID")). "</b>:<br>\n";
- echo "\t\t<textarea name=\"Question\" rows=\"3\" cols=\"80\">".
- mysql_result($Erg, 0, "Question"). "</textarea>\n";
- echo "<br><br>Antwort der Erzengel:<br>\n";
- if (mysql_result($Erg, 0, "Answer")=="")
- echo "\t\t<textarea name=\"Answer\" rows=\"5\" cols=\"80\">".
- "Bitte hier die Antwort eintragen...</textarea><br>\n";
- else
- echo "\t\t<textarea name=\"Answer\" rows=\"5\" cols=\"80\">".
- mysql_result($Erg, 0, "Answer"). "</textarea>\n<br>\n";
- echo "\t\t<input type=\"hidden\" name=\"QID\" value=\"". $_GET["QID"]. "\">\n";
- echo "\t\t<input type=\"hidden\" name=\"quest\" value=\"save\">\n";
- echo "\t\t<input type=\"submit\" value=\"Sichern...\">\n";
- echo "\t</form>\n";
- if (mysql_result($Erg, 0, "AID")<>"0")
- {
- echo "\tDu kannst diese Anfrage so wie sie ist, als Engel-FAQ eintrag &uuml;bernehmen.<br>\n";
- echo "<a href=\"./faq.php?quest=transfer&QID=". $_GET["QID"]. "\">Als FAQ-Eintrag sichern...</a>\n";
- }
- } // Abfrage der QID
- break;
+ if (!IsSet($_GET["QID"]))
+ echo "\t\tFehlerhafter Aufruf...<br />Bitte die Bearbeitung nochmals beginnen :)\n";
+ else
+ {
+ $SQL = "SELECT * FROM `Questions` WHERE `QID`='". $_GET["QID"]. "'";
+ $Erg = mysql_query($SQL, $con);
+ echo "\t\t<form action=\"./faq.php\" method=\"GET\">\n";
+ echo "\t\tAnfrage von <b>". UID2NICK(mysql_result($Erg, 0, "UID")). "</b>:<br />\n";
+ echo "\t\t<textarea name=\"Question\" rows=\"3\" cols=\"80\">".
+ mysql_result($Erg, 0, "Question"). "</textarea>\n";
+ echo "<br /><br />Antwort der Erzengel:<br />\n";
+ if (mysql_result($Erg, 0, "Answer")=="")
+ echo "\t\t<textarea name=\"Answer\" rows=\"5\" cols=\"80\">".
+ "Bitte hier die Antwort eintragen...</textarea><br />\n";
+ else
+ echo "\t\t<textarea name=\"Answer\" rows=\"5\" cols=\"80\">".
+ mysql_result($Erg, 0, "Answer"). "</textarea>\n<br />\n";
+ echo "\t\t<input type=\"hidden\" name=\"QID\" value=\"". $_GET["QID"]. "\">\n";
+ echo "\t\t<input type=\"hidden\" name=\"quest\" value=\"save\">\n";
+ echo "\t\t<input type=\"submit\" value=\"Sichern...\">\n";
+ echo "\t</form>\n";
+ if (mysql_result($Erg, 0, "AID")<>"0")
+ {
+ echo "\tDu kannst diese Anfrage so wie sie ist, als Engel-FAQ eintrag &uuml;bernehmen.<br />\n";
+ echo "<a href=\"./faq.php?quest=transfer&QID=". $_GET["QID"]. "\">Als FAQ-Eintrag sichern...</a>\n";
+ }
+ } // Abfrage der QID
+ break;
case "save":
- if (!IsSet($_GET["QID"]))
- echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...";
+ if (!IsSet($_GET["QID"]))
+ echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...";
else
- {
- $SQL = "UPDATE `Questions` SET `Question`='". $_GET["Question"].
- "', `AID`='". $_SESSION['UID']. "' , `Answer`='". $_GET["Answer"]. "' ".
- "WHERE `QID`='". $_GET["QID"]. "' LIMIT 1";
- $Erg = db_query($SQL, "save Question");
- if ($Erg == 1)
- {
- echo "\tDer Eintrag wurde ge&auml;ndert<br>\n";
- SetHeaderGo2Back();
- }
- else
- echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
+ {
+ $SQL = "UPDATE `Questions` SET `Question`='". $_GET["Question"].
+ "', `AID`='". $_SESSION['UID']. "' , `Answer`='". $_GET["Answer"]. "' ".
+ "WHERE `QID`='". $_GET["QID"]. "' LIMIT 1";
+ $Erg = db_query($SQL, "save Question");
+ if ($Erg == 1)
+ {
+ echo "\tDer Eintrag wurde ge&auml;ndert<br />\n";
+ SetHeaderGo2Back();
+ }
+ else
+ echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
}
- break;
+ break;
case "transfer":
- if (!IsSet($_GET["QID"]))
- echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
- else
- {
- $SQL1="SELECT * FROM `Questions` WHERE `QID`='". $_GET["QID"]. "'";
- $Erg = mysql_query($SQL1, $con);
- $SQL2="INSERT INTO `FAQ` Values ('', '".
- mysql_result($Erg, 0, "Question")."', '".mysql_result($Erg, 0, "Answer")."')";
- $Erg = db_query($SQL2, "trasfert to request to the FAQ");
- if ($Erg == 1)
- echo "\tDer Eintrag wurde &uuml;bertragen.<br>\n";
- else
- echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
- }
-
- break;
+ if (!IsSet($_GET["QID"]))
+ echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
+ else
+ {
+ $SQL1="SELECT * FROM `Questions` WHERE `QID`='". $_GET["QID"]. "'";
+ $Erg = mysql_query($SQL1, $con);
+ $SQL2="INSERT INTO `FAQ` Values ('', '".
+ mysql_result($Erg, 0, "Question")."', '".mysql_result($Erg, 0, "Answer")."')";
+ $Erg = db_query($SQL2, "trasfert to request to the FAQ");
+ if ($Erg == 1)
+ echo "\tDer Eintrag wurde &uuml;bertragen.<br />\n";
+ else
+ echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
+ }
+
+ break;
// *---------------------------------------------------------------------------
// * FAQ - Bearbeitung
@@ -143,105 +143,105 @@ case "transfer":
// * geaendert oder geloscht werden...
// *---------------------------------------------------------------------------
case "faq":
- $quest_bearb=0; // keine Fragenliste anzeigen, FAQ editieren...
- echo "\tFAQ-Liste:<br>";
- echo "<a href=\"./faq.php?quest=faqnew\">Neuen Eintrag</a>";
-
- $SQL = "SELECT * FROM `FAQ`";
- $Erg = mysql_query($SQL, $con);
+ $quest_bearb=0; // keine Fragenliste anzeigen, FAQ editieren...
+ echo "\tFAQ-Liste:<br />";
+ echo "<a href=\"./faq.php?quest=faqnew\">Neuen Eintrag</a>";
+
+ $SQL = "SELECT * FROM `FAQ`";
+ $Erg = mysql_query($SQL, $con);
- // anzahl zeilen
- $Zeilen = mysql_num_rows($Erg);
+ // anzahl zeilen
+ $Zeilen = mysql_num_rows($Erg);
- for ($n = 0 ; $n < $Zeilen ; $n++)
- if (mysql_result($Erg, $n, "Antwort")!="")
- {
- echo "\t<p class=\"question\">". mysql_result($Erg, $n, "Frage"). "</p>\n";
- echo "\t<p class=\"answetion\">". mysql_result($Erg, $n, "Antwort")."</p>\n";
- echo "\t<a href=\"./faq.php?quest=faqedit&FAQID=". mysql_result($Erg, $n, "FID").
- "\">Bearbeiten</a>\n<br>---<br>\n";
- }
- break;
+ for ($n = 0 ; $n < $Zeilen ; $n++)
+ if (mysql_result($Erg, $n, "Antwort")!="")
+ {
+ echo "\t<p class=\"question\">". mysql_result($Erg, $n, "Frage"). "</p>\n";
+ echo "\t<p class=\"answetion\">". mysql_result($Erg, $n, "Antwort")."</p>\n";
+ echo "\t<a href=\"./faq.php?quest=faqedit&FAQID=". mysql_result($Erg, $n, "FID").
+ "\">Bearbeiten</a>\n<br />---<br />\n";
+ }
+ break;
case "faqedit":
if (!IsSet($_GET["FAQID"]))
- echo "\tFehlerhafter Aufruf...<br>Bitte die Bearbeitung nochmals beginnen :)\n";
- else
- {
- $SQL = "SELECT * FROM `FAQ` WHERE `FID`='". $_GET["FAQID"]. "'";
- $Erg = mysql_query($SQL, $con);
+ echo "\tFehlerhafter Aufruf...<br />Bitte die Bearbeitung nochmals beginnen :)\n";
+ else
+ {
+ $SQL = "SELECT * FROM `FAQ` WHERE `FID`='". $_GET["FAQID"]. "'";
+ $Erg = mysql_query($SQL, $con);
- // anzahl zeilen
- $Zeilen = mysql_num_rows($Erg);
+ // anzahl zeilen
+ $Zeilen = mysql_num_rows($Erg);
?>
- <form action="./faq.php" method="GET">
- Frage:<br>
- <textarea name="Frage" rows="3" cols="80"><?php echo mysql_result($Erg, 0, "Frage"); ?></textarea>
- <br><br>
- Antwort:<br>
- <textarea name="Antwort" rows="5" cols="80"><?php echo mysql_result($Erg, 0, "Antwort"); ?></textarea><br>
- <input type="hidden" name="FAQID" value="<?PHP echo $_GET["FAQID"]; ?>">
- <input type="hidden" name="quest" value="faqsave">
- <input type="submit" value="Sichern...">
- </form>
- <form action="./faq.php">
- <input type="hidden" name="FAQID" value="<?PHP echo $_GET["FAQID"]; ?>">
+ <form action="./faq.php" method="GET">
+ Frage:<br />
+ <textarea name="Frage" rows="3" cols="80"><?php echo mysql_result($Erg, 0, "Frage"); ?></textarea>
+ <br /><br />
+ Antwort:<br />
+ <textarea name="Antwort" rows="5" cols="80"><?php echo mysql_result($Erg, 0, "Antwort"); ?></textarea><br />
+ <input type="hidden" name="FAQID" value="<?php echo $_GET["FAQID"]; ?>">
+ <input type="hidden" name="quest" value="faqsave">
+ <input type="submit" value="Sichern...">
+ </form>
+ <form action="./faq.php">
+ <input type="hidden" name="FAQID" value="<?php echo $_GET["FAQID"]; ?>">
<input type="hidden" name="quest" value="faqdelete">
<input type="submit" value="L&ouml;schen...">
- </form>
+ </form>
<?php
- }
- break;
+ }
+ break;
case "faqdelete";
- if (!IsSet($_GET["FAQID"]))
- echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
- else
- {
- $SQL = "DELETE FROM `FAQ` WHERE `FID`='". $_GET["FAQID"]. "' LIMIT 1";
- $Erg = db_query($SQL, "delate faq item");
- if ($Erg == 1)
- echo "\tDer Eintrag wurde gel&ouml;scht<br>\n";
- else
- echo "\tEin Fehler ist aufgetreten. Ist der Eintag bereits gel&ouml;scht gewesen?\n";
- }
- break;
+ if (!IsSet($_GET["FAQID"]))
+ echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
+ else
+ {
+ $SQL = "DELETE FROM `FAQ` WHERE `FID`='". $_GET["FAQID"]. "' LIMIT 1";
+ $Erg = db_query($SQL, "delate faq item");
+ if ($Erg == 1)
+ echo "\tDer Eintrag wurde gel&ouml;scht<br />\n";
+ else
+ echo "\tEin Fehler ist aufgetreten. Ist der Eintag bereits gel&ouml;scht gewesen?\n";
+ }
+ break;
case "faqsave";
if (!IsSet($_GET["FAQID"]))
- echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
+ echo "\tFehlerhafter Aufruf... Bitte die Bearbeitung nochmal starten...\n";
else
- {
- $SQL = "UPDATE `FAQ` SET `Frage`='". $_GET["Frage"]. "', `Antwort`='". $_GET["Antwort"].
- "' WHERE `FID`='". $_GET["FAQID"]. "' LIMIT 1";
- $Erg = db_query($SQL, $con);
- if ($Erg == 1)
- echo "\tDer Eintrag wurde ge&auml;ndert<br>\n";
- else
- echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
+ {
+ $SQL = "UPDATE `FAQ` SET `Frage`='". $_GET["Frage"]. "', `Antwort`='". $_GET["Antwort"].
+ "' WHERE `FID`='". $_GET["FAQID"]. "' LIMIT 1";
+ $Erg = db_query($SQL, $con);
+ if ($Erg == 1)
+ echo "\tDer Eintrag wurde ge&auml;ndert<br />\n";
+ else
+ echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
}
- break;
+ break;
case "faqnew":
?>
- <form action="./faq.php" method="GET">
- Frage:<br>
- <textarea name="Frage" rows="3" cols="80">Frage...</textarea><br><br>
- Antwort:<br>
- <textarea name="Antwort" rows="5" cols="80">Antwort</textarea><br>
+ <form action="./faq.php" method="GET">
+ Frage:<br />
+ <textarea name="Frage" rows="3" cols="80">Frage...</textarea><br /><br />
+ Antwort:<br />
+ <textarea name="Antwort" rows="5" cols="80">Antwort</textarea><br />
<input type="hidden" name="quest" value="faqnewsave">
<input type="submit" value="Sichern...">
</form>
<?php
- break;
+ break;
case "faqnewsave";
$SQL = "INSERT INTO `FAQ` VALUES ('', '". $_GET["Frage"]. "', '". $_GET["Antwort"]. "')";
$Erg = db_query($SQL, "Save new FAQ entry");
if ($Erg == 1)
- echo "\tDer Eintrag wurde erfasst.<br>\n";
+ echo "\tDer Eintrag wurde erfasst.<br />\n";
else
- echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
+ echo "\tEin Fehler ist aufgetreten. Sorry, du kannst es aber ja nochmal probieren :)\n";
break;
} //switch ($_GET["quest"])
@@ -251,32 +251,32 @@ case "faqnewsave";
// Fragenliste anzeigen???
if ($quest_bearb==1)
{
- $Erg = mysql_query($SQL, $con);
- // anzahl zeilen
- $Zeilen = mysql_num_rows($Erg);
+ $Erg = mysql_query($SQL, $con);
+ // anzahl zeilen
+ $Zeilen = mysql_num_rows($Erg);
- if ($Zeilen==0)
- echo "\tkeine vorhanden...\n";
- else
- for ($n = 0 ; $n < $Zeilen ; $n++)
- {
- echo "\t<p>". nl2br(mysql_result($Erg, $n, "Question"))."\n</p><br>\n";
- echo "\t<a href=\"./faq.php?quest=edit&QID=". mysql_result($Erg, $n, "QID"). "\">Bearbeiten</a>\n";
- echo "<br>---<br>\n";
- }
-
+ if ($Zeilen==0)
+ echo "\tkeine vorhanden...\n";
+ else
+ for ($n = 0 ; $n < $Zeilen ; $n++)
+ {
+ echo "\t<p>". nl2br(mysql_result($Erg, $n, "Question"))."\n</p><br />\n";
+ echo "\t<a href=\"./faq.php?quest=edit&QID=". mysql_result($Erg, $n, "QID"). "\">Bearbeiten</a>\n";
+ echo "<br />---<br />\n";
+ }
+
}
} //if (IsSet($_GET["quest"]))
else
{
- echo "Bitte w&auml;hle aus, ob du:\n";
- echo "<ul>\n";
- echo "\t<li><a href=\"./faq.php?quest=all\">Alle Anfragen anzeigen/bearbeiten m&ouml;chtest</a></li>\n";
- echo "\t<li><a href=\"./faq.php?quest=open\">Alle offenen Anfragen anzeigen/bearbeiten m&ouml;chtest (".
- noAnswer(). ")</a></li>\n";
- echo "\t<li><a href=\"./faq.php?quest=faq\">Die FAQ's anzeigen/bearbeiten</a></li>\n";
- echo "</ul>\n";
+ echo "Bitte w&auml;hle aus, ob du:\n";
+ echo "<ul>\n";
+ echo "\t<li><a href=\"./faq.php?quest=all\">Alle Anfragen anzeigen/bearbeiten m&ouml;chtest</a></li>\n";
+ echo "\t<li><a href=\"./faq.php?quest=open\">Alle offenen Anfragen anzeigen/bearbeiten m&ouml;chtest (".
+ noAnswer(). ")</a></li>\n";
+ echo "\t<li><a href=\"./faq.php?quest=faq\">Die FAQ's anzeigen/bearbeiten</a></li>\n";
+ echo "</ul>\n";
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/free.php b/www-ssl/admin/free.php
index 5ceaebb6..577ef7be 100755..100644
--- a/www-ssl/admin/free.php
+++ b/www-ssl/admin/free.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Erzengel";
$header = "Freie Engel";
@@ -6,9 +6,9 @@ include ("../../../camp2011/includes/header.php");
include ("../../../camp2011/includes/funktion_db_list.php");
-echo "Hallo ".$_SESSION['Nick'].",<br>\n";
+echo "Hallo ".$_SESSION['Nick'].",<br />\n";
-echo "<br><br>\n\nHier findest du alle Engel, welche zur Zeit in keiner Schicht verplant sind:<br><br>\n";
+echo "<br /><br />\n\nHier findest du alle Engel, welche zur Zeit in keiner Schicht verplant sind:<br /><br />\n";
#######################################################
@@ -21,21 +21,21 @@ echo "<br><br>\n\nHier findest du alle Engel, welche zur Zeit in keiner Schicht
/* geht nicht ??? unter stabel !!
$SQL= "SELECT User.Nick, Schichtplan.*, Schichtbelegung.* ".
- "FROM Schichtplan, User LEFT OUTER ".
- "JOIN Schichtbelegung ON User.UID=Schichtbelegung.UID ".
- "WHERE Schichtplan.SID = Schichtbelegung.SID AND ".
- "Schichtplan.Date < now() and ".
- "Schichtplan.EndDate > now() ".
- "ORDER BY Nick";
-
+ "FROM Schichtplan, User LEFT OUTER ".
+ "JOIN Schichtbelegung ON User.UID=Schichtbelegung.UID ".
+ "WHERE Schichtplan.SID = Schichtbelegung.SID AND ".
+ "Schichtplan.Date < now() and ".
+ "Schichtplan.EndDate > now() ".
+ "ORDER BY Nick";
+
$SQL = "SELECT Shifts.*, ShiftEntry.*, User.Nick ".
- "FROM User ".
- "INNER JOIN (Shifts INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID) ON User.UID = ShiftEntry.UID ".
- "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() );";
+ "FROM User ".
+ "INNER JOIN (Shifts INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID) ON User.UID = ShiftEntry.UID ".
+ "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() );";
*/
$SQL = "SELECT Shifts.*, ShiftEntry.* ".
- "FROM `Shifts` INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID ".
- "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() AND ShiftEntry.UID>0);";
+ "FROM `Shifts` INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID ".
+ "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() AND ShiftEntry.UID>0);";
//SELECT User.Nick, Schichtplan.*, Schichtbelegung. * FROM User LEFT JOIN Schichtbelegung ON User.UID=Schichtbelegung.UID, Schichtplan LEFT JOIN Schichtbelegung ON Schichtplan.SID = Schichtbelegung.SID WHERE Schichtplan.Date < now() and Schichtplan.EndDate > now() ORDER BY Nick
@@ -62,27 +62,27 @@ echo "\t</tr>\n";
$inuse="";
for ($i=0; $i < $Zeilen; $i++)
{
- echo "<tr class=\"content\">\n";
- echo "<td><a href=\"./userChangeNormal.php?Type=Normal&enterUID=". mysql_result($Erg, $i, "UID"). "\">".
- UID2Nick(mysql_result($Erg, $i, "UID")). "</td></a>\n";
- echo "<td></td>\n";
- echo "<td>". mysql_result($Erg, $i, "RID"). "</td>\n";
- echo "<td>". mysql_result($Erg, $i, "DateS"). "</td>\n";
- echo "<td>". mysql_result($Erg, $i, "DateE"). "</td>\n";
- echo "</tr>\n";
-
- if ($inuse!="")
- $inuse.= " OR ";
- $inuse.= "(Nick = \"". UID2Nick(mysql_result($Erg, $i, "UID")). "\")";
+ echo "<tr class=\"content\">\n";
+ echo "<td><a href=\"./userChangeNormal.php?Type=Normal&enterUID=". mysql_result($Erg, $i, "UID"). "\">".
+ UID2Nick(mysql_result($Erg, $i, "UID")). "</td></a>\n";
+ echo "<td></td>\n";
+ echo "<td>". mysql_result($Erg, $i, "RID"). "</td>\n";
+ echo "<td>". mysql_result($Erg, $i, "DateS"). "</td>\n";
+ echo "<td>". mysql_result($Erg, $i, "DateE"). "</td>\n";
+ echo "</tr>\n";
+
+ if ($inuse!="")
+ $inuse.= " OR ";
+ $inuse.= "(Nick = \"". UID2Nick(mysql_result($Erg, $i, "UID")). "\")";
}
if ($inuse!="")
- $inuse=" WHERE NOT (".$inuse.")";
+ $inuse=" WHERE NOT (".$inuse.")";
echo "</table>\n";
//##########################################################################################################
-echo "<br><br>\n\nhier findest du alle Engel, welche zur Zeit in keiner Schichten verplant sind:<br><br>\n";
+echo "<br /><br />\n\nhier findest du alle Engel, welche zur Zeit in keiner Schichten verplant sind:<br /><br />\n";
echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\"\>\n";
echo "\t<tr class=\"contenttopic\">\n\t\t<td>Nick</td>\n\t\t<td>DECT</td>\n\t</tr>\n";
@@ -91,11 +91,11 @@ $Erg = mysql_query($SQL, $con);
$Zeilen = mysql_num_rows($Erg);
for ($i=0; $i < $Zeilen; $i++)
{
- echo "\t<tr class=\"content\">\n";
- echo "\t\t<td><a href=\"./userChangeNormal.php?Type=Normal&enterUID=". mysql_result($Erg, $i, "UID"). "\">".
- mysql_result($Erg, $i, "Nick"). "</a></td>\n";
- echo "\t\t<td>". mysql_result($Erg, $i, "DECT"). "</td>\n";
- echo "\n</tr>\n";
+ echo "\t<tr class=\"content\">\n";
+ echo "\t\t<td><a href=\"./userChangeNormal.php?Type=Normal&enterUID=". mysql_result($Erg, $i, "UID"). "\">".
+ mysql_result($Erg, $i, "Nick"). "</a></td>\n";
+ echo "\t\t<td>". mysql_result($Erg, $i, "DECT"). "</td>\n";
+ echo "\n</tr>\n";
}
echo "</table>\n";
diff --git a/www-ssl/admin/free_DECT.php b/www-ssl/admin/free_DECT.php
index c28c78af..83a4123f 100755..100644
--- a/www-ssl/admin/free_DECT.php
+++ b/www-ssl/admin/free_DECT.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
include ("../../../camp2011/includes/config_db.php");
include ("../../../camp2011/includes/funktion_db_list.php");
@@ -12,8 +12,8 @@ include ("../../../camp2011/includes/funktion_user.php");
#######################################################
$SQL = "SELECT Shifts.*, ShiftEntry.* ".
- "FROM `Shifts` INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID ".
- "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() AND ShiftEntry.UID>0);";
+ "FROM `Shifts` INNER JOIN ShiftEntry ON Shifts.SID = ShiftEntry.SID ".
+ "WHERE (Shifts.DateS<=Now() AND Shifts.DateE>=Now() AND ShiftEntry.UID>0);";
$Erg = mysql_query($SQL, $con);
$Zeilen = mysql_num_rows($Erg);
@@ -21,17 +21,17 @@ $Zeilen = mysql_num_rows($Erg);
$inuse="";
for ($i=0; $i < $Zeilen; $i++)
{
- if ($inuse!="")
- $inuse.= " OR ";
- $inuse.= "(UID = \"". mysql_result($Erg, $i, "UID"). "\")";
+ if ($inuse!="")
+ $inuse.= " OR ";
+ $inuse.= "(UID = \"". mysql_result($Erg, $i, "UID"). "\")";
}
if ($inuse!="")
{
- $inuse=" WHERE (NOT (".$inuse.")) AND (DECT!='')";
+ $inuse=" WHERE (NOT (".$inuse.")) AND (DECT!='')";
}
else
{
- $inuse=" WHERE (DECT!='')";
+ $inuse=" WHERE (DECT!='')";
}
@@ -42,36 +42,36 @@ $Erg = mysql_query($SQL, $con);
$Zeilen = mysql_num_rows($Erg);
for ($i=0; $i < $Zeilen; $i++)
{
- // get DECT number
- echo mysql_result($Erg, $i, "DECT"). "\t";
+ // get DECT number
+ echo mysql_result($Erg, $i, "DECT"). "\t";
- // get all user rights
- $SQL_RIGHT = "SELECT * FROM UserCVS WHERE UID=". mysql_result($Erg, $i, "UID"). ";";
- $Erg_RIGHT = mysql_query($SQL_RIGHT, $con);
- $UserRights = mysql_fetch_array($Erg_RIGHT);
+ // get all user rights
+ $SQL_RIGHT = "SELECT * FROM UserCVS WHERE UID=". mysql_result($Erg, $i, "UID"). ";";
+ $Erg_RIGHT = mysql_query($SQL_RIGHT, $con);
+ $UserRights = mysql_fetch_array($Erg_RIGHT);
- foreach( $UserRights as $Var => $Value)
- {
- if( (strpos( $Var, ".php") === false) AND
- (strpos( $Var, "/") === false) AND
- (strpos( $Var, "UID") === false) AND
- (is_numeric($Var) === false) )
- {
- echo "\"".$Var. "\"=". $Value. "\t";
- }
- }
+ foreach( $UserRights as $Var => $Value)
+ {
+ if( (strpos( $Var, ".php") === false) AND
+ (strpos( $Var, "/") === false) AND
+ (strpos( $Var, "UID") === false) AND
+ (is_numeric($Var) === false) )
+ {
+ echo "\"".$Var. "\"=". $Value. "\t";
+ }
+ }
- // get shift types
- $SQL_TYPES = "SELECT TID FROM `ShiftEntry` WHERE UID=". mysql_result($Erg, $i, "UID"). " GROUP BY TID;";
- $Erg_TYPES = mysql_query($SQL_TYPES, $con);
- $Zeilen_Typen = mysql_num_rows($Erg_TYPES);
- for ($j=0; $j < $Zeilen_Typen; $j++)
- {
- echo "\"TID_". TID2Type( mysql_result($Erg_TYPES, $j, "TID")). "\"=Y\t";
- }
+ // get shift types
+ $SQL_TYPES = "SELECT TID FROM `ShiftEntry` WHERE UID=". mysql_result($Erg, $i, "UID"). " GROUP BY TID;";
+ $Erg_TYPES = mysql_query($SQL_TYPES, $con);
+ $Zeilen_Typen = mysql_num_rows($Erg_TYPES);
+ for ($j=0; $j < $Zeilen_Typen; $j++)
+ {
+ echo "\"TID_". TID2Type( mysql_result($Erg_TYPES, $j, "TID")). "\"=Y\t";
+ }
- echo "\n";
-// echo "<br>";
+ echo "\n";
+// echo "<br />";
}
?>
diff --git a/www-ssl/admin/group.php b/www-ssl/admin/group.php
index 57945d0d..f42fea97 100755..100644
--- a/www-ssl/admin/group.php
+++ b/www-ssl/admin/group.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Editieren der Engelliste";
@@ -7,40 +7,40 @@ include ("../../../camp2011/includes/funktion_db_list.php");
if (!IsSet($_GET["enterGID"]))
{
- // Userliste, keine UID uebergeben...
-
- $SQL = "SELECT * FROM `UserGroups` ORDER BY `Name` ASC";
- $Erg = mysql_query($SQL, $con);
- echo mysql_error($con);
-
- // anzahl zeilen
- $Zeilen = mysql_num_rows($Erg);
-
- echo "<table class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
- echo "<tr class=\"contenttopic\">\n";
- echo "\t<td>Groupname</td>\n";
- echo "\t<td>Link</td>\n";
- echo "</tr>\n";
-
- for ($n = 0 ; $n < $Zeilen ; $n++) {
- echo "<tr class=\"content\">\n";
- echo "\t<td>".mysql_result($Erg, $n, "Name")."</td>\n";
-
- echo "<td><a href=\"./userChangeSecure.php?enterUID=".
- mysql_result($Erg, $n, "UID")."&Type=Secure\">change</a></td>\n";
- echo "</tr>\n";
- }
-
- // new form
- echo "<tr class=\"content\">\n";
- echo "\t<form action=\"userSaveSecure.php?new=newGroup\" method=\"POST\">\n";
- echo "\t\t<td><input name=\"GroupName\" type=\"text\" value=\"--new group--\"></td>\n";
- echo "\t\t<td><input type=\"submit\" name=\"Send\" value=\"Save\"></td>\n";
- echo "\t</form>\n";
- echo "</tr>\n";
-
- echo "\t</table>\n";
- // Ende Userliste
+ // Userliste, keine UID uebergeben...
+
+ $SQL = "SELECT * FROM `UserGroups` ORDER BY `Name` ASC";
+ $Erg = mysql_query($SQL, $con);
+ echo mysql_error($con);
+
+ // anzahl zeilen
+ $Zeilen = mysql_num_rows($Erg);
+
+ echo "<table class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
+ echo "<tr class=\"contenttopic\">\n";
+ echo "\t<td>Groupname</td>\n";
+ echo "\t<td>Link</td>\n";
+ echo "</tr>\n";
+
+ for ($n = 0 ; $n < $Zeilen ; $n++) {
+ echo "<tr class=\"content\">\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Name")."</td>\n";
+
+ echo "<td><a href=\"./userChangeSecure.php?enterUID=".
+ mysql_result($Erg, $n, "UID")."&Type=Secure\">change</a></td>\n";
+ echo "</tr>\n";
+ }
+
+ // new form
+ echo "<tr class=\"content\">\n";
+ echo "\t<form action=\"userSaveSecure.php?new=newGroup\" method=\"POST\">\n";
+ echo "\t\t<td><input name=\"GroupName\" type=\"text\" value=\"--new group--\"></td>\n";
+ echo "\t\t<td><input type=\"submit\" name=\"Send\" value=\"Save\"></td>\n";
+ echo "\t</form>\n";
+ echo "</tr>\n";
+
+ echo "\t</table>\n";
+ // Ende Userliste
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/index.php b/www-ssl/admin/index.php
index b89bdb93..e7be285c 100755..100644
--- a/www-ssl/admin/index.php
+++ b/www-ssl/admin/index.php
@@ -1,19 +1,19 @@
-<?PHP
+<?php
$title = "Erzengel";
$header = "Index";
include ("../../../camp2011/includes/header.php");
include ("../../../camp2011/includes/funktion_db_list.php");
-echo "Hallo Erzengel ".$_SESSION['Nick'].",<br>\n";
+echo "Hallo Erzengel ".$_SESSION['Nick'].",<br />\n";
?>
-du bist jetzt im Erzengel-Bereich. Hier kannst du die Engel-Verwaltung vornehmen.<br><br>
+du bist jetzt im Erzengel-Bereich. Hier kannst du die Engel-Verwaltung vornehmen.<br /><br />
Bitte melde dich <a href="../logout.php">hier</a> nach getaner Arbeit immer ab, damit kein anderer hier &Auml;nderungen vornehmen kann.
-<?PHP
+<?php
include ("../../../camp2011/includes/footer.php");
?>
diff --git a/www-ssl/admin/news.php b/www-ssl/admin/news.php
index 78f49ee2..f25eab93 100755..100644
--- a/www-ssl/admin/news.php
+++ b/www-ssl/admin/news.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Newsverwaltung";
$header = "Verwaltung der News";
@@ -8,14 +8,14 @@ include ("../../../camp2011/includes/funktion_db_list.php");
if (!IsSet($_GET["action"]))
{
- $SQL = "SELECT * FROM `News` ORDER BY `Datum` DESC";
- $Erg = mysql_query($SQL, $con);
+ $SQL = "SELECT * FROM `News` ORDER BY `Datum` DESC";
+ $Erg = mysql_query($SQL, $con);
- $rowcount = mysql_num_rows($Erg);
- ?>
-Hallo <?PHP echo $_SESSION['Nick'] ?>, <br>
+ $rowcount = mysql_num_rows($Erg);
+ ?>
+Hallo <?php echo $_SESSION['Nick'] ?>, <br />
hier kannst du die News s&auml;ubern... falls jemand auf die Idee kommt,
-hier herumzuspamen oder aus Versehen falsche Informationen zu hinterlegen :)<br><br>
+hier herumzuspamen oder aus Versehen falsche Informationen zu hinterlegen :)<br /><br />
<table width="100%" class="border" cellpadding="2" cellspacing="1">
<tr class="contenttopic">
@@ -24,97 +24,97 @@ hier herumzuspamen oder aus Versehen falsche Informationen zu hinterlegen :)<br>
<td>Text</td>
<td>Erfasser</td>
<td>Engeltreff</td>
- <td>&Auml;nd.</td>
- </tr>
-<?PHP
-
- for ($i=0; $i < $rowcount; $i++)
- {
- echo "\t<tr class=\"content\">\n";
- echo "\t <td>".mysql_result($Erg, $i, "Datum")."</td>";
- echo "\t <td>".mysql_result($Erg, $i, "Betreff")."</td>";
- echo "\t <td>".mysql_result($Erg, $i, "Text")."</td>";
- echo "\t <td>".UID2Nick(mysql_result($Erg, $i, "UID"))."</td>";
- echo "\t <td>".mysql_result($Erg, $i, "Treffen")."</td>";
- echo "\t <td><a href=\"./news.php?action=change&date=".mysql_result($Erg, $i, "Datum")."\">XXX</a></td>";
- echo "\t</tr>\n";
- }
- echo "</table>";
+ <td>&Auml;nd.</td>
+ </tr>
+<?php
+
+ for ($i=0; $i < $rowcount; $i++)
+ {
+ echo "\t<tr class=\"content\">\n";
+ echo "\t <td>".mysql_result($Erg, $i, "Datum")."</td>";
+ echo "\t <td>".mysql_result($Erg, $i, "Betreff")."</td>";
+ echo "\t <td>".mysql_result($Erg, $i, "Text")."</td>";
+ echo "\t <td>".UID2Nick(mysql_result($Erg, $i, "UID"))."</td>";
+ echo "\t <td>".mysql_result($Erg, $i, "Treffen")."</td>";
+ echo "\t <td><a href=\"./news.php?action=change&date=".mysql_result($Erg, $i, "Datum")."\">XXX</a></td>";
+ echo "\t</tr>\n";
+ }
+ echo "</table>";
}
else
{
- unSet($chsql);
-
- switch ($_GET["action"])
- {
- case 'change':
- if (isset($_GET["date"]))
- {
- $SQL = "SELECT * FROM `News` WHERE (`Datum`='". $_GET["date"]. "')";
- $Erg = mysql_query($SQL, $con);
-
- if( mysql_num_rows( $Erg)>0)
- {
- echo "<form action=\"./news.php\" method=\"GET\">\n";
-
- echo "<table>\n";
- echo " <tr><td>Datum</td><td><input type=\"text\" size=\"40\" name=\"date\" value=\"".
- mysql_result($Erg, 0, "Datum")."\" disabled></td></tr>\n";
- echo " <tr><td>Betreff</td><td><input type=\"text\" size=\"40\" name=\"eBetreff\" value=\"".
- mysql_result($Erg, 0, "Betreff")."\"></td></tr>\n";
- echo " <tr><td>Text</td><td><textarea rows=\"10\" cols=\"80\" name=\"eText\">".
- mysql_result($Erg, 0, "Text")."</textarea></td></tr>\n";
- echo " <tr><td>Engel</td><td><input type=\"text\" size=\"40\" name=\"eUser\" value=\"".
- UID2Nick(mysql_result($Erg, 0, "UID"))."\" disabled></td></tr>\n";
- echo " <tr><td>Treffen</td><td><input type=\"text\" size=\"40\" name=\"eTreffen\" value=\"".
- mysql_result($Erg, 0, "Treffen")."\"></td></tr>\n";
- echo "</table>";
-
- echo "<input type=\"hidden\" name=\"date\" value=\"". $_GET["date"]. "\">\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"change_save\">\n";
- echo "<input type=\"submit\" value=\"Abschicken...\">\n";
- echo "</form>";
-
- echo "<form action=\"./news.php?action=delete\" method=\"POST\">\n";
- echo "<input type=\"hidden\" name=\"date\" value=\"". $_GET["date"]. "\">\n";
- echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
- echo "</form>";
- }
- else
- echo "FEHLER: Eintrag \"". $_GET["date"]. "\" nicht gefunden";
- }
- else
- echo "Fehler: \"date\" nicht übergeben";
- break;
-
- case 'change_save':
- if( isset($_GET["date"]) && isset($_GET["eBetreff"]) && isset($_GET["eText"]) )
- $chsql="UPDATE `News` SET `Betreff`='". $_GET["eBetreff"]. "', `Text`='". $_GET["eText"].
- "', `Treffen`='". $_GET["eTreffen"]. "' WHERE (`Datum`='". $_GET["date"]. "') limit 1";
- else
- echo "Fehler: nicht genügend parameter übergeben";
- break;
-
- case 'delete':
- if (isset($_POST["date"]))
- $chsql="DELETE FROM `News` WHERE `Datum`='". $_POST["date"]. "' LIMIT 1";
- else
- echo "Fehler: \"date\" nicht übergeben";
- break;
- } //SWITCH
-
- if (IsSet($chsql))
- {
- // SQL-Statement ausführen...
- $Erg = mysql_query($chsql, $con);
- If ($Erg == 1)
- echo "&Auml;nderung erfolgreich gesichert...";
- else
- echo "Ein Fehler ist aufgetreten... probiere es am besten nocheinmal... :)<br><br>\n".
- mysql_error($con). "<br><br>\n[$chsql]";
- SetHeaderGo2Back();
- }
+ unSet($chsql);
+
+ switch ($_GET["action"])
+ {
+ case 'change':
+ if (isset($_GET["date"]))
+ {
+ $SQL = "SELECT * FROM `News` WHERE (`Datum`='". $_GET["date"]. "')";
+ $Erg = mysql_query($SQL, $con);
+
+ if( mysql_num_rows( $Erg)>0)
+ {
+ echo "<form action=\"./news.php\" method=\"GET\">\n";
+
+ echo "<table>\n";
+ echo " <tr><td>Datum</td><td><input type=\"text\" size=\"40\" name=\"date\" value=\"".
+ mysql_result($Erg, 0, "Datum")."\" disabled></td></tr>\n";
+ echo " <tr><td>Betreff</td><td><input type=\"text\" size=\"40\" name=\"eBetreff\" value=\"".
+ mysql_result($Erg, 0, "Betreff")."\"></td></tr>\n";
+ echo " <tr><td>Text</td><td><textarea rows=\"10\" cols=\"80\" name=\"eText\">".
+ mysql_result($Erg, 0, "Text")."</textarea></td></tr>\n";
+ echo " <tr><td>Engel</td><td><input type=\"text\" size=\"40\" name=\"eUser\" value=\"".
+ UID2Nick(mysql_result($Erg, 0, "UID"))."\" disabled></td></tr>\n";
+ echo " <tr><td>Treffen</td><td><input type=\"text\" size=\"40\" name=\"eTreffen\" value=\"".
+ mysql_result($Erg, 0, "Treffen")."\"></td></tr>\n";
+ echo "</table>";
+
+ echo "<input type=\"hidden\" name=\"date\" value=\"". $_GET["date"]. "\">\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"change_save\">\n";
+ echo "<input type=\"submit\" value=\"Abschicken...\">\n";
+ echo "</form>";
+
+ echo "<form action=\"./news.php?action=delete\" method=\"POST\">\n";
+ echo "<input type=\"hidden\" name=\"date\" value=\"". $_GET["date"]. "\">\n";
+ echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
+ echo "</form>";
+ }
+ else
+ echo "FEHLER: Eintrag \"". $_GET["date"]. "\" nicht gefunden";
+ }
+ else
+ echo "Fehler: \"date\" nicht übergeben";
+ break;
+
+ case 'change_save':
+ if( isset($_GET["date"]) && isset($_GET["eBetreff"]) && isset($_GET["eText"]) )
+ $chsql="UPDATE `News` SET `Betreff`='". $_GET["eBetreff"]. "', `Text`='". $_GET["eText"].
+ "', `Treffen`='". $_GET["eTreffen"]. "' WHERE (`Datum`='". $_GET["date"]. "') limit 1";
+ else
+ echo "Fehler: nicht genügend parameter übergeben";
+ break;
+
+ case 'delete':
+ if (isset($_POST["date"]))
+ $chsql="DELETE FROM `News` WHERE `Datum`='". $_POST["date"]. "' LIMIT 1";
+ else
+ echo "Fehler: \"date\" nicht übergeben";
+ break;
+ } //SWITCH
+
+ if (IsSet($chsql))
+ {
+ // SQL-Statement ausführen...
+ $Erg = mysql_query($chsql, $con);
+ If ($Erg == 1)
+ echo "&Auml;nderung erfolgreich gesichert...";
+ else
+ echo "Ein Fehler ist aufgetreten... probiere es am besten nocheinmal... :)<br /><br />\n".
+ mysql_error($con). "<br /><br />\n[$chsql]";
+ SetHeaderGo2Back();
+ }
}// IF-ELSE
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/room.php b/www-ssl/admin/room.php
index ebbe1e36..09006675 100755..100644
--- a/www-ssl/admin/room.php
+++ b/www-ssl/admin/room.php
@@ -9,36 +9,36 @@ $Erg = mysql_query($Sql, $con);
if( !IsSet($_GET["action"]) )
{
- echo "Hallo ".$_SESSION['Nick'].
- ",<br>\nhier hast du die M&ouml;glichkeit, neue R&auml;ume f&uuml;r die Schichtpl&auml;ne einzutragen ".
- "oder vorhandene abzu&auml;ndern:<br><br>\n";
-
- echo "<a href=\"./room.php?action=new\">- Neuen Raum/Ort eintragen</a><br>\n";
-
- echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
- echo "<tr class=\"contenttopic\">\n";
-
- for( $i = 1; $i < mysql_num_fields($Erg); $i++ )
- {
- if( substr( mysql_field_name($Erg, $i), 0, 12) == "DEFAULT_EID_")
- echo "\t<td> Anzahl ". $EngelTypeID[substr( mysql_field_name($Erg, $i), 12)]. "</td>";
- else
- echo "\t<td>". mysql_field_name($Erg, $i)."</td>";
- }
- echo "\t<td>&Auml;ndern</td>";
- echo "</tr>";
-
- for( $t = 0; $t < mysql_num_rows($Erg); $t++ )
- {
- echo "\t<tr class=\"content\">\n";
- for ($j = 1; $j < mysql_num_fields($Erg); $j++)
- {
- echo "\t\t<td>".mysql_result($Erg, $t, $j)."</td>\n";
- }
- echo "\t\t<td><a href=\"./room.php?action=change&RID=".mysql_result($Erg, $t, "RID")."\">###</a></td>\n";
- echo "\t</tr>\n";
- } // ende Auflistung Raeume
- echo "</table>";
+ echo "Hallo ".$_SESSION['Nick'].
+ ",<br />\nhier hast du die M&ouml;glichkeit, neue R&auml;ume f&uuml;r die Schichtpl&auml;ne einzutragen ".
+ "oder vorhandene abzu&auml;ndern:<br /><br />\n";
+
+ echo "<a href=\"./room.php?action=new\">- Neuen Raum/Ort eintragen</a><br />\n";
+
+ echo "<table width=\"100%\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n";
+ echo "<tr class=\"contenttopic\">\n";
+
+ for( $i = 1; $i < mysql_num_fields($Erg); $i++ )
+ {
+ if( substr( mysql_field_name($Erg, $i), 0, 12) == "DEFAULT_EID_")
+ echo "\t<td> Anzahl ". $EngelTypeID[substr( mysql_field_name($Erg, $i), 12)]. "</td>";
+ else
+ echo "\t<td>". mysql_field_name($Erg, $i)."</td>";
+ }
+ echo "\t<td>&Auml;ndern</td>";
+ echo "</tr>";
+
+ for( $t = 0; $t < mysql_num_rows($Erg); $t++ )
+ {
+ echo "\t<tr class=\"content\">\n";
+ for ($j = 1; $j < mysql_num_fields($Erg); $j++)
+ {
+ echo "\t\t<td>".mysql_result($Erg, $t, $j)."</td>\n";
+ }
+ echo "\t\t<td><a href=\"./room.php?action=change&RID=".mysql_result($Erg, $t, "RID")."\">###</a></td>\n";
+ echo "\t</tr>\n";
+ } // ende Auflistung Raeume
+ echo "</table>";
}
else
{
@@ -48,132 +48,132 @@ UnSet($SQL);
switch ($_GET["action"]) {
case 'new':
- echo "Neuen Raum einrichten: <br>";
- echo "<form action=\"./room.php\" method=\"GET\">\n";
- echo "<table>\n";
-
- for( $Uj = 1; $Uj < mysql_num_fields($Erg); $Uj++ )
- {
- if( (mysql_field_name($Erg, $Uj) == "show") || (mysql_field_name($Erg, $Uj) == "FromPentabarf") )
- {
- echo "<tr><td>". mysql_field_name($Erg, $Uj). "</td>".
- "<td>".
- "<input type=\"radio\" name=\"". mysql_field_name($Erg, $Uj). "\" value=\"Y\">Yes".
- "<input type=\"radio\" name=\"". mysql_field_name($Erg, $Uj). "\" value=\"N\">No".
- "</td></tr>\n";
- }
- else
- {
- //sonderfall fuer Default Engel
- if( substr( mysql_field_name($Erg, $Uj), 0, 12) == "DEFAULT_EID_")
- $FeldName = "Anzahl ". $EngelTypeID[substr( mysql_field_name($Erg, $Uj), 12)];
- else
- $FeldName = mysql_field_name($Erg, $Uj);
-
- echo "<td>$FeldName</td>".
- "<td><input type=\"text\" size=\"40\" name=\"".mysql_field_name($Erg, $Uj)."\">";
- echo "</td></tr>\n";
- }
- }
- echo "</table>\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"newsave\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
- break;
+ echo "Neuen Raum einrichten: <br />";
+ echo "<form action=\"./room.php\" method=\"GET\">\n";
+ echo "<table>\n";
+
+ for( $Uj = 1; $Uj < mysql_num_fields($Erg); $Uj++ )
+ {
+ if( (mysql_field_name($Erg, $Uj) == "show") || (mysql_field_name($Erg, $Uj) == "FromPentabarf") )
+ {
+ echo "<tr><td>". mysql_field_name($Erg, $Uj). "</td>".
+ "<td>".
+ "<input type=\"radio\" name=\"". mysql_field_name($Erg, $Uj). "\" value=\"Y\">Yes".
+ "<input type=\"radio\" name=\"". mysql_field_name($Erg, $Uj). "\" value=\"N\">No".
+ "</td></tr>\n";
+ }
+ else
+ {
+ //sonderfall fuer Default Engel
+ if( substr( mysql_field_name($Erg, $Uj), 0, 12) == "DEFAULT_EID_")
+ $FeldName = "Anzahl ". $EngelTypeID[substr( mysql_field_name($Erg, $Uj), 12)];
+ else
+ $FeldName = mysql_field_name($Erg, $Uj);
+
+ echo "<td>$FeldName</td>".
+ "<td><input type=\"text\" size=\"40\" name=\"".mysql_field_name($Erg, $Uj)."\">";
+ echo "</td></tr>\n";
+ }
+ }
+ echo "</table>\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"newsave\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
+ break;
case 'newsave':
- $vars = $_GET;
- $count = count($vars) - 1;
- $vars = array_splice($vars, 0, $count);
- $Keys = "";
- $Values = "";
- foreach($vars as $key => $value)
- {
- $Keys .= ", `$key`";
- $Values .= ", '$value'";
- }
- $SQL = "INSERT INTO `Room` (". substr( $Keys, 2). ") VALUES (". substr( $Values, 2). ")";
- SetHeaderGo2Back();
- break;
+ $vars = $_GET;
+ $count = count($vars) - 1;
+ $vars = array_splice($vars, 0, $count);
+ $Keys = "";
+ $Values = "";
+ foreach($vars as $key => $value)
+ {
+ $Keys .= ", `$key`";
+ $Values .= ", '$value'";
+ }
+ $SQL = "INSERT INTO `Room` (". substr( $Keys, 2). ") VALUES (". substr( $Values, 2). ")";
+ SetHeaderGo2Back();
+ break;
case 'change':
- if (! IsSet($_GET["RID"]))
- echo "Fehlerhafter Aufruf!";
- else
- {
- $SQL2 = "SELECT * FROM `Room` WHERE `RID`='". $_GET["RID"]. "'";
- $ERG = mysql_query($SQL2, $con);
-
- if( mysql_num_rows( $ERG)>0)
- {
- echo "Raum ab&auml;ndern:\n";
- echo "Hier kannst du eintragen, welche und wieviele Engel f&uuml;r den Raum zur Verf?gung stehen m&uuml;ssen.";
- echo "<form action=\"./room.php\" method=\"GET\">\n";
- echo "<table>\n";
-
- for ($Uj = 1; $Uj < mysql_num_fields($ERG); $Uj++)
- {
- if( (mysql_field_name($ERG, $Uj) == "show") || (mysql_field_name($ERG, $Uj) == "FromPentabarf") )
- {
- echo "<tr><td>". mysql_field_name($Erg, $Uj). "</td>".
- "<td>".
- "<input type=\"radio\" name=\"e". mysql_field_name($ERG, $Uj).
- "\" value=\"Y\"". (mysql_result($ERG, 0, $Uj)=='Y'? " checked":""). ">Yes".
- "<input type=\"radio\" name=\"e". mysql_field_name($ERG, $Uj).
- "\" value=\"N\"". (mysql_result($ERG, 0, $Uj)=='N'? " checked":""). ">No".
- "</td></tr>\n";
- }
- else
- {
- if( substr( mysql_field_name($ERG, $Uj), 0, 12) == "DEFAULT_EID_")
- //sonderfall fuer Default Engel
- $FeldName = "Anzahl ". $EngelTypeID[substr( mysql_field_name($ERG, $Uj), 12)];
- else
- $FeldName = mysql_field_name($ERG, $Uj);
- echo "<tr><td>$FeldName</td>".
- "<td><input type=\"text\" size=\"40\" name=\"e".mysql_field_name($ERG, $Uj)."\" ".
- "value=\"".mysql_result($ERG, 0, $Uj)."\">".
- "</td></tr>\n";
- }
- }
- echo "</table>\n";
- echo "<input type=\"hidden\" name=\"eRID\" value=\"". $_GET["RID"]. "\">\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"changesave\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
- echo "<form action=\"./room.php\" method=\"GET\">\n";
- echo "<input type=\"hidden\" name=\"RID\" value=\"". $_GET["RID"]. "\">\n";
- echo "<input type=\"hidden\" name=\"action\" value=\"delete\">\n";
- echo "<input type=\"submit\" value=\"L&ouml;schen...\">";
- echo "</form>";
- }
- else
- echo "FEHLER: Room ID ". $_GET["RID"]. " nicht gefunden";
- }
- break;
-
+ if (! IsSet($_GET["RID"]))
+ echo "Fehlerhafter Aufruf!";
+ else
+ {
+ $SQL2 = "SELECT * FROM `Room` WHERE `RID`='". $_GET["RID"]. "'";
+ $ERG = mysql_query($SQL2, $con);
+
+ if( mysql_num_rows( $ERG)>0)
+ {
+ echo "Raum ab&auml;ndern:\n";
+ echo "Hier kannst du eintragen, welche und wieviele Engel f&uuml;r den Raum zur Verf?gung stehen m&uuml;ssen.";
+ echo "<form action=\"./room.php\" method=\"GET\">\n";
+ echo "<table>\n";
+
+ for ($Uj = 1; $Uj < mysql_num_fields($ERG); $Uj++)
+ {
+ if( (mysql_field_name($ERG, $Uj) == "show") || (mysql_field_name($ERG, $Uj) == "FromPentabarf") )
+ {
+ echo "<tr><td>". mysql_field_name($Erg, $Uj). "</td>".
+ "<td>".
+ "<input type=\"radio\" name=\"e". mysql_field_name($ERG, $Uj).
+ "\" value=\"Y\"". (mysql_result($ERG, 0, $Uj)=='Y'? " checked":""). ">Yes".
+ "<input type=\"radio\" name=\"e". mysql_field_name($ERG, $Uj).
+ "\" value=\"N\"". (mysql_result($ERG, 0, $Uj)=='N'? " checked":""). ">No".
+ "</td></tr>\n";
+ }
+ else
+ {
+ if( substr( mysql_field_name($ERG, $Uj), 0, 12) == "DEFAULT_EID_")
+ //sonderfall fuer Default Engel
+ $FeldName = "Anzahl ". $EngelTypeID[substr( mysql_field_name($ERG, $Uj), 12)];
+ else
+ $FeldName = mysql_field_name($ERG, $Uj);
+ echo "<tr><td>$FeldName</td>".
+ "<td><input type=\"text\" size=\"40\" name=\"e".mysql_field_name($ERG, $Uj)."\" ".
+ "value=\"".mysql_result($ERG, 0, $Uj)."\">".
+ "</td></tr>\n";
+ }
+ }
+ echo "</table>\n";
+ echo "<input type=\"hidden\" name=\"eRID\" value=\"". $_GET["RID"]. "\">\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"changesave\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
+ echo "<form action=\"./room.php\" method=\"GET\">\n";
+ echo "<input type=\"hidden\" name=\"RID\" value=\"". $_GET["RID"]. "\">\n";
+ echo "<input type=\"hidden\" name=\"action\" value=\"delete\">\n";
+ echo "<input type=\"submit\" value=\"L&ouml;schen...\">";
+ echo "</form>";
+ }
+ else
+ echo "FEHLER: Room ID ". $_GET["RID"]. " nicht gefunden";
+ }
+ break;
+
case 'changesave':
- $sql="";
- $vars = $_GET;
- $count = count($vars) - 2;
- $vars = array_splice($vars, 0, $count);
- foreach($vars as $key => $value)
- {
- $keys = substr($key,1);
- $sql .= ", `".$keys."`='".$value."' ";
- }
- $SQL = "UPDATE `Room` SET ". substr($sql, 2). " WHERE `RID`='". $_GET["eRID"]. "'";
- SetHeaderGo2Back();
- break;
+ $sql="";
+ $vars = $_GET;
+ $count = count($vars) - 2;
+ $vars = array_splice($vars, 0, $count);
+ foreach($vars as $key => $value)
+ {
+ $keys = substr($key,1);
+ $sql .= ", `".$keys."`='".$value."' ";
+ }
+ $SQL = "UPDATE `Room` SET ". substr($sql, 2). " WHERE `RID`='". $_GET["eRID"]. "'";
+ SetHeaderGo2Back();
+ break;
case 'delete':
- if (IsSet($_GET["RID"])) {
- $SQL="DELETE FROM `Room` WHERE `RID`='". $_GET["RID"]. "'";
- } else {
- echo "Fehlerhafter Aufruf";
- }
- SetHeaderGo2Back();
- break;
+ if (IsSet($_GET["RID"])) {
+ $SQL="DELETE FROM `Room` WHERE `RID`='". $_GET["RID"]. "'";
+ } else {
+ echo "Fehlerhafter Aufruf";
+ }
+ SetHeaderGo2Back();
+ break;
} //switch
@@ -181,17 +181,17 @@ case 'delete':
// Update ???
if (IsSet($SQL)){
-// echo $SQL;
- // hier muesste das SQL ausgefuehrt werden...
- $Erg = db_query($SQL, "exec SQL");
- if ($Erg == 1)
- echo "&Auml;nderung wurde gesichert...<br>";
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)";
- echo "<br><br>".mysql_error( $con ). "<br>($SQL)<br>";
- }
-} // Ende Update
+// echo $SQL;
+ // hier muesste das SQL ausgefuehrt werden...
+ $Erg = db_query($SQL, "exec SQL");
+ if ($Erg == 1)
+ echo "&Auml;nderung wurde gesichert...<br />";
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)";
+ echo "<br /><br />".mysql_error( $con ). "<br />($SQL)<br />";
+ }
+} // Ende Update
} //IF IsSet($action)
diff --git a/www-ssl/admin/schichtplan.1.php b/www-ssl/admin/schichtplan.1.php
index 30761390..30761390 100755..100644
--- a/www-ssl/admin/schichtplan.1.php
+++ b/www-ssl/admin/schichtplan.1.php
diff --git a/www-ssl/admin/schichtplan.php b/www-ssl/admin/schichtplan.php
index ba2f8d66..af3cd7d4 100755..100644
--- a/www-ssl/admin/schichtplan.php
+++ b/www-ssl/admin/schichtplan.php
@@ -6,59 +6,59 @@ include ("../../../camp2011/includes/header.php");
function executeSQL( $SQL)
{
- global $DEBUG, $con;
-
- $Erg = mysql_query($SQL, $con);
- if( $DEBUG )
- echo "DEBUG SQL: $SQL<br>\n";
- if ($Erg == 1)
- {
- echo "SQL war erfolgreich";
- }
- else
- {
- echo "SQL Fehler (". mysql_error($con).")" ;
- }
+ global $debug, $con;
+
+ $Erg = mysql_query($SQL, $con);
+ if( $debug )
+ echo "DEBUG SQL: $SQL<br />\n";
+ if ($Erg == 1)
+ {
+ echo "SQL war erfolgreich";
+ }
+ else
+ {
+ echo "SQL Fehler (". mysql_error($con).")" ;
+ }
}
if (!IsSet($_GET["action"])) {
-echo "Hallo ".$_SESSION['Nick'].",<br>\n";
-echo "hier kannst du Schichten anlegen, &auml;ndern oder l&ouml;schen.<br><br>";
-echo "<a href=\"./shiftadd.php\">Neue Schicht einplanen</a><br><br>\n\n";
+echo "Hallo ".$_SESSION['Nick'].",<br />\n";
+echo "hier kannst du Schichten anlegen, &auml;ndern oder l&ouml;schen.<br /><br />";
+echo "<a href=\"./shiftadd.php\">Neue Schicht einplanen</a><br /><br />\n\n";
echo "<form action=\"".$_SERVER['SCRIPT_NAME']."\" method=\"GET\" >\n";
?>
<table width="100%" class="border" cellpadding="2" cellspacing="1">
- <tr class="contenttopic">
- <td></td>
- <td>Datum</td>
- <td>Raum</td>
- <td>Dauer</td>
- <td>&Auml;ndern</td>
- </tr>
-<?PHP
+ <tr class="contenttopic">
+ <td></td>
+ <td>Datum</td>
+ <td>Raum</td>
+ <td>Dauer</td>
+ <td>&Auml;ndern</td>
+ </tr>
+<?php
$sql = "SELECT `SID`, `DateS`, `RID`, `Len` FROM `Shifts` ".
- "ORDER BY `RID`, `DateS` ";
+ "ORDER BY `RID`, `DateS` ";
$Erg = mysql_query($sql, $con);
$rowcount = mysql_num_rows($Erg);
for( $i = 0; $i < $rowcount; $i++)
{
- echo "\t<tr class=\"content\">\n";
- echo "\t\t<td><input type=\"checkbox\" name=\"SID". mysql_result($Erg, $i, "SID"). "\" ".
- "value=\"". mysql_result($Erg, $i, "SID"). "\"></td>\n";
- echo "\t\t<td>".mysql_result($Erg, $i, "DateS")."</td>\n";
+ echo "\t<tr class=\"content\">\n";
+ echo "\t\t<td><input type=\"checkbox\" name=\"SID". mysql_result($Erg, $i, "SID"). "\" ".
+ "value=\"". mysql_result($Erg, $i, "SID"). "\"></td>\n";
+ echo "\t\t<td>".mysql_result($Erg, $i, "DateS")."</td>\n";
- $sql2= "SELECT `Name` FROM `Room` WHERE `RID`='".mysql_result($Erg, $i, "RID")."'";
- $Erg2 = mysql_query($sql2, $con);
- if( mysql_num_rows($Erg2) > 0)
- echo "\t\t<td>".mysql_result($Erg2, 0, "Name")."</td>\n";
- else
- echo "\t\t<td>Unbenkannt (RID=". mysql_result($Erg, $i, "RID"). ")</td>\n";
- echo "\t\t<td>".mysql_result($Erg, $i, "Len")." Std. </td>\n";
- echo "\t\t<td><a href=\"./schichtplan.php?action=change&SID=".
- mysql_result($Erg, $i, "SID")."\">####</a></td>\n";
- echo "\t</tr>\n";
+ $sql2= "SELECT `Name` FROM `Room` WHERE `RID`='".mysql_result($Erg, $i, "RID")."'";
+ $Erg2 = mysql_query($sql2, $con);
+ if( mysql_num_rows($Erg2) > 0)
+ echo "\t\t<td>".mysql_result($Erg2, 0, "Name")."</td>\n";
+ else
+ echo "\t\t<td>Unbenkannt (RID=". mysql_result($Erg, $i, "RID"). ")</td>\n";
+ echo "\t\t<td>".mysql_result($Erg, $i, "Len")." Std. </td>\n";
+ echo "\t\t<td><a href=\"./schichtplan.php?action=change&SID=".
+ mysql_result($Erg, $i, "SID")."\">####</a></td>\n";
+ echo "\t</tr>\n";
}
echo "</table>\n";
@@ -75,317 +75,317 @@ UnSet($chSQL);
switch ($_GET["action"]){
case 'change':
- if ( !IsSet($_GET["SID"]) )
- {
- echo "Fehlerhafter Aufruf!\n";
- }
- else
- {
-
- $sql = "SELECT * FROM `Shifts` WHERE (`SID` = '". $_GET["SID"]. "' )";
- $Erg = mysql_query($sql, $con);
+ if ( !IsSet($_GET["SID"]) )
+ {
+ echo "Fehlerhafter Aufruf!\n";
+ }
+ else
+ {
+
+ $sql = "SELECT * FROM `Shifts` WHERE (`SID` = '". $_GET["SID"]. "' )";
+ $Erg = mysql_query($sql, $con);
- echo "Schicht ab&auml;ndern: <br>\n";
+ echo "Schicht ab&auml;ndern: <br />\n";
- // Anzeige Allgemeiner schaischt daten
+ // Anzeige Allgemeiner schaischt daten
echo "<form action=\"".$_SERVER['SCRIPT_NAME']."\" method=\"GET\" >";
echo "<table>\n";
echo " <tr><td>Schichtbeginn</td>".
- "<td><input value=\"". mysql_result($Erg, 0, "DateS").
- "\" type=\"text\" size=\"40\" name=\"eDate\"></td></tr>\n";
- echo " <tr><td>Raum</td><td>\n<select name=\"eRID\">\n";
-
- $sql2 = "SELECT `RID`, `Name`, `FromPentabarf` FROM `Room`";
+ "<td><input value=\"". mysql_result($Erg, 0, "DateS").
+ "\" type=\"text\" size=\"40\" name=\"eDate\"></td></tr>\n";
+ echo " <tr><td>Raum</td><td>\n<select name=\"eRID\">\n";
+
+ $sql2 = "SELECT `RID`, `Name`, `FromPentabarf` FROM `Room`";
$Erg2 = mysql_query($sql2, $con);
- $rowcount = mysql_num_rows($Erg2);
- $FromPentabarf = "N";
- for( $i = 0; $i < $rowcount; $i++ )
- {
- $RID=mysql_result($Erg2, $i, "RID");
- echo " <option value=\"".$RID."\"";
- if( $RID == mysql_result($Erg, 0, "RID") )
- {
- echo " selected";
- $FromPentabarf = mysql_result($Erg2, $i, "FromPentabarf");
- }
- echo ">".mysql_result($Erg2, $i, "Name")."</option>\n";
- }
- echo " </select>\n</td></tr>\n";
-
- echo " <tr><td>Dauer in h</td>".
- "<td><input value=\"". mysql_result($Erg, 0, "Len").
- "\" type=\"text\" size=\"40\" name=\"eDauer\"></td></tr>\n";
- echo " <tr><td>Beschreibung</td>".
- "<td><input value=\"". mysql_result($Erg, 0, "Man").
- "\" type=\"text\" size=\"40\" name=\"eName\"></td></tr>\n";
- echo " <tr><td>URL</td>".
- "<td><input value=\"". mysql_result($Erg, 0, "URL").
- "\" type=\"text\" size=\"40\" name=\"eURL\"></td></tr>\n";
- if( $FromPentabarf == "Y")
- {
- echo " <tr><td></td>".
- "<td><h1>!!! Imported from Pentabarf !!!</h1></td></tr>\n";
- }
+ $rowcount = mysql_num_rows($Erg2);
+ $FromPentabarf = "N";
+ for( $i = 0; $i < $rowcount; $i++ )
+ {
+ $RID=mysql_result($Erg2, $i, "RID");
+ echo " <option value=\"".$RID."\"";
+ if( $RID == mysql_result($Erg, 0, "RID") )
+ {
+ echo " selected";
+ $FromPentabarf = mysql_result($Erg2, $i, "FromPentabarf");
+ }
+ echo ">".mysql_result($Erg2, $i, "Name")."</option>\n";
+ }
+ echo " </select>\n</td></tr>\n";
+
+ echo " <tr><td>Dauer in h</td>".
+ "<td><input value=\"". mysql_result($Erg, 0, "Len").
+ "\" type=\"text\" size=\"40\" name=\"eDauer\"></td></tr>\n";
+ echo " <tr><td>Beschreibung</td>".
+ "<td><input value=\"". mysql_result($Erg, 0, "Man").
+ "\" type=\"text\" size=\"40\" name=\"eName\"></td></tr>\n";
+ echo " <tr><td>URL</td>".
+ "<td><input value=\"". mysql_result($Erg, 0, "URL").
+ "\" type=\"text\" size=\"40\" name=\"eURL\"></td></tr>\n";
+ if( $FromPentabarf == "Y")
+ {
+ echo " <tr><td></td>".
+ "<td><h1>!!! Imported from Pentabarf !!!</h1></td></tr>\n";
+ }
echo "</table>\n";
-
+
echo "<input type=\"hidden\" name=\"SID\" value=\"". $_GET["SID"]. "\">\n";
echo "<input type=\"hidden\" name=\"action\" value=\"changesave\">\n";
echo "<input type=\"submit\" value=\"sichern...\">\n";
echo "</form>\n\n";
- // Löschen
- echo "<form action=\"". $_SERVER['SCRIPT_NAME']. "\" method=\"GET\" >\n";
+ // Löschen
+ echo "<form action=\"". $_SERVER['SCRIPT_NAME']. "\" method=\"GET\" >\n";
echo "<input type=\"hidden\" name=\"SID\" value=\"". $_GET["SID"]. "\">\n";
echo "<input type=\"hidden\" name=\"action\" value=\"delete\">\n";
echo "<input type=\"submit\" value=\"L&ouml;schen...\">\n";
echo "</form>\n\n";
-
- echo "<b>ACHTUNG:</b><br>\n";
- echo "Beim L&ouml;schen werden die bisher eingetragenen Engel f&uuml;r diese Schicht mitgel&ouml;scht.<br>\n";
+
+ echo "<b>ACHTUNG:</b><br />\n";
+ echo "Beim L&ouml;schen werden die bisher eingetragenen Engel f&uuml;r diese Schicht mitgel&ouml;scht.<br />\n";
- echo "<br><hr>\n\n\n\n";
-
- //Freie Engelschichten
- $sql3 = "SELECT `TID` FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND `UID`='0'";
- $Erg3 = mysql_query($sql3, $con);
- $rowcount = mysql_num_rows($Erg3);
-
- echo "Folgende Engelschichten sind noch nicht vergeben.\n";
- echo "Und koenen, wenn diese nSchicht nicht benoetigt wird geloet werden:<br>\n";
- for ($j=0; $j < $rowcount; $j++)
- {
- $TID = mysql_result($Erg3, $j, 0);
- echo "<a href=\"./schichtplan.php?action=engelshiftdel&SID=". $_GET["SID"]. "&TID=$TID\">".
- "freie ". TID2Type($TID). Get_Text("inc_schicht_Engel"). "schicht loeschen</a><br>\n";
- }
- echo "<br><hr>\n\n\n\n";
+ echo "<br /><hr>\n\n\n\n";
+
+ //Freie Engelschichten
+ $sql3 = "SELECT `TID` FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND `UID`='0'";
+ $Erg3 = mysql_query($sql3, $con);
+ $rowcount = mysql_num_rows($Erg3);
+
+ echo "Folgende Engelschichten sind noch nicht vergeben.\n";
+ echo "Und koenen, wenn diese nSchicht nicht benoetigt wird geloet werden:<br />\n";
+ for ($j=0; $j < $rowcount; $j++)
+ {
+ $TID = mysql_result($Erg3, $j, 0);
+ echo "<a href=\"./schichtplan.php?action=engelshiftdel&SID=". $_GET["SID"]. "&TID=$TID\">".
+ "freie ". TID2Type($TID). Get_Text("inc_schicht_Engel"). "schicht loeschen</a><br />\n";
+ }
+ echo "<br /><hr>\n\n\n\n";
- //Ausgabe eingetragener schischten
- $sql3 = "SELECT * FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND NOT `UID`='0'";
- $Erg3 = mysql_query($sql3, $con);
- $rowcount = mysql_num_rows($Erg3);
-
- echo "Folgende Engel Sind fuer die Schicht eingetargen.\n";
- echo "Und koennen, wenn diese nicht zu Schicht erschienen sind ausgetragen werden:<br>\n";
- echo "<table border=\"1\">\n".
- "<tr class=\"contenttopic\">".
- "<th>nick</th>".
- "<th>type</th>".
- "<th>normal</th>".
- "<th>freeloader :-(</th>".
- "</tr>";
-
- for ($j=0; $j < $rowcount; $j++)
- {
- $userUID=mysql_result($Erg3, $j, "UID");
- echo "\t<tr>\n";
- echo "\t\t<td>". UID2Nick($userUID). "</td>\n";
- echo "\t\t<td>". TID2Type(mysql_result($Erg3, $j, "TID")). Get_Text("inc_schicht_Engel"). "</td>\n";
- echo "\t\t<td><a href=\"./schichtplan.php?action=engeldel&SID=". $_GET["SID"]. "&UIDs=$userUID&freeloader=0\">###-austragen-###</a></td>\n";
- echo "\t\t<td><a href=\"./schichtplan.php?action=engeldel&SID=". $_GET["SID"]. "&UIDs=$userUID&freeloader=1\">###-austragen-freeloader-###</a></td>\n";
- echo "\t</tr>\n";
- } // FOR
+ //Ausgabe eingetragener schischten
+ $sql3 = "SELECT * FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND NOT `UID`='0'";
+ $Erg3 = mysql_query($sql3, $con);
+ $rowcount = mysql_num_rows($Erg3);
+
+ echo "Folgende Engel Sind fuer die Schicht eingetargen.\n";
+ echo "Und koennen, wenn diese nicht zu Schicht erschienen sind ausgetragen werden:<br />\n";
+ echo "<table border=\"1\">\n".
+ "<tr class=\"contenttopic\">".
+ "<th>nick</th>".
+ "<th>type</th>".
+ "<th>normal</th>".
+ "<th>freeloader :-(</th>".
+ "</tr>";
+
+ for ($j=0; $j < $rowcount; $j++)
+ {
+ $userUID=mysql_result($Erg3, $j, "UID");
+ echo "\t<tr>\n";
+ echo "\t\t<td>". UID2Nick($userUID). "</td>\n";
+ echo "\t\t<td>". TID2Type(mysql_result($Erg3, $j, "TID")). Get_Text("inc_schicht_Engel"). "</td>\n";
+ echo "\t\t<td><a href=\"./schichtplan.php?action=engeldel&SID=". $_GET["SID"]. "&UIDs=$userUID&freeloader=0\">###-austragen-###</a></td>\n";
+ echo "\t\t<td><a href=\"./schichtplan.php?action=engeldel&SID=". $_GET["SID"]. "&UIDs=$userUID&freeloader=1\">###-austragen-freeloader-###</a></td>\n";
+ echo "\t</tr>\n";
+ } // FOR
- echo "</table><br><hr>\n\n\n\n";
+ echo "</table><br /><hr>\n\n\n\n";
- //Nachtragen von Engeln
- echo "Hat ein anderer Engel die Schicht &uuml;bernommen, trage ihn bitte ein:";
- echo "<form action=\"".$_SERVER['SCRIPT_NAME']."\" method=\"GET\" >\n";
- echo "<input type=\"hidden\" name=\"SID\" value=\"". $_GET["SID"]. "\">\n";
+ //Nachtragen von Engeln
+ echo "Hat ein anderer Engel die Schicht &uuml;bernommen, trage ihn bitte ein:";
+ echo "<form action=\"".$_SERVER['SCRIPT_NAME']."\" method=\"GET\" >\n";
+ echo "<input type=\"hidden\" name=\"SID\" value=\"". $_GET["SID"]. "\">\n";
echo "<input type=\"hidden\" name=\"action\" value=\"engeladd\">\n";
-
- // Listet alle Nicks auf
- echo "<select name=\"UIDs\">\n";
- if( $FromPentabarf != "Y")
- {
- echo "\t<option value=\"0\">--neu--</option>\n";
- }
-
- $usql="SELECT * FROM `User` ORDER BY `Nick`";
- $uErg = mysql_query($usql, $con);
- $urowcount = mysql_num_rows($uErg);
- for ($k=0; $k<$urowcount; $k++)
- {
- echo "\t<option value=\"".mysql_result($uErg, $k, "UID")."\">".
- mysql_result($uErg, $k, "Nick").
- "</option>\n";
- }
- echo "</select>\n";
-
- echo " als \n";
-
- // holt eine liste der benötigten Engel zu dieser Schischt
- $sql3 = "SELECT Count(`TID`) AS `CTID`, `TID` FROM `ShiftEntry` ";
- $sql3.= "WHERE (`SID`='". $_GET["SID"]. "' AND `UID`='0') ";
- $sql3.= "GROUP BY `SID`, `TID`, `UID` ";
- $Erg3 = mysql_query($sql3, $con);
- $i=-1;
- while( ++$i < mysql_num_rows($Erg3))
- {
- $EngelNeed[mysql_result($Erg3, $i, "TID")] = mysql_result($Erg3, $i, "CTID");
- }
-
- // Gibt dei möglich Engeltypen aus und zeigt wíefiel noch beötigt werden
- echo "<select name=\"TID\">\n";
- $SQL2 = "SELECT `TID`, `Name` FROM `EngelType` ORDER BY `Name`";
- $Erg2 = mysql_query($SQL2, $con);
+
+ // Listet alle Nicks auf
+ echo "<select name=\"UIDs\">\n";
+ if( $FromPentabarf != "Y")
+ {
+ echo "\t<option value=\"0\">--neu--</option>\n";
+ }
+
+ $usql="SELECT * FROM `User` ORDER BY `Nick`";
+ $uErg = mysql_query($usql, $con);
+ $urowcount = mysql_num_rows($uErg);
+ for ($k=0; $k<$urowcount; $k++)
+ {
+ echo "\t<option value=\"".mysql_result($uErg, $k, "UID")."\">".
+ mysql_result($uErg, $k, "Nick").
+ "</option>\n";
+ }
+ echo "</select>\n";
+
+ echo " als \n";
+
+ // holt eine liste der benötigten Engel zu dieser Schischt
+ $sql3 = "SELECT Count(`TID`) AS `CTID`, `TID` FROM `ShiftEntry` ";
+ $sql3.= "WHERE (`SID`='". $_GET["SID"]. "' AND `UID`='0') ";
+ $sql3.= "GROUP BY `SID`, `TID`, `UID` ";
+ $Erg3 = mysql_query($sql3, $con);
+ $i=-1;
+ while( ++$i < mysql_num_rows($Erg3))
+ {
+ $EngelNeed[mysql_result($Erg3, $i, "TID")] = mysql_result($Erg3, $i, "CTID");
+ }
+
+ // Gibt dei möglich Engeltypen aus und zeigt wíefiel noch beötigt werden
+ echo "<select name=\"TID\">\n";
+ $SQL2 = "SELECT `TID`, `Name` FROM `EngelType` ORDER BY `Name`";
+ $Erg2 = mysql_query($SQL2, $con);
for ($l = 0; $l < mysql_num_rows($Erg2); $l++)
- {
- $EngelTID = mysql_result($Erg2, $l, "TID");
- echo "<option value=\"$EngelTID\">";
- echo mysql_result($Erg2, $l, "Name"). Get_Text("inc_schicht_engel");
- if( !isset($EngelNeed[$EngelTID]) )
- echo " (0)";
- else
- echo " (".$EngelNeed[$EngelTID].")";
- echo "</option>\n";
+ {
+ $EngelTID = mysql_result($Erg2, $l, "TID");
+ echo "<option value=\"$EngelTID\">";
+ echo mysql_result($Erg2, $l, "Name"). Get_Text("inc_schicht_engel");
+ if( !isset($EngelNeed[$EngelTID]) )
+ echo " (0)";
+ else
+ echo " (".$EngelNeed[$EngelTID].")";
+ echo "</option>\n";
}
- echo "</select>\n";
-
- echo "<input type=\"submit\" value=\"eintragen...\">\n";
-
- echo "<br>\n<input value=\"1\" type=\"text\" size=\"5\" name=\"eAnzahlNew\"> Anzahl New\n";
-
- echo "</form>";
+ echo "</select>\n";
+
+ echo "<input type=\"submit\" value=\"eintragen...\">\n";
+
+ echo "<br />\n<input value=\"1\" type=\"text\" size=\"5\" name=\"eAnzahlNew\"> Anzahl New\n";
+
+ echo "</form>";
- } // IF ISSET(
- break;
+ } // IF ISSET(
+ break;
case 'engeladd':
- if( $_GET["UIDs"]>0)
- {
-
- $SQL = "SELECT * FROM `ShiftEntry` ".
- "WHERE (`SID`='". $_GET["SID"]. "' AND `TID`='". $_GET["TID"]. "' AND `UID`='0')";
- $ERG = mysql_query($SQL, $con);
- if( mysql_num_rows($ERG) != 0 )
- {
- $chSQL = "UPDATE `ShiftEntry` SET ".
- "`UID`='". $_GET["UIDs"]. "', `Comment`='shift added by ".$_SESSION['Nick']."' ".
- "WHERE (`SID`='". $_GET["SID"]. "' AND ".
- "`TID`='". $_GET["TID"]. "' AND `UID`='0' ) LIMIT 1";
- }
- else
- {
- $chSQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`, `UID`, `Comment`) VALUES (".
- "'". $_GET["SID"]. "', '". $_GET["TID"]. "', ".
- "'". $_GET["UIDs"]. "', 'shift added by ".$_SESSION['Nick']."')";
- }
- echo "Es wird folgende Schicht zus&auml;tzlich eingetragen:<br>\n";
- echo "Engel: ".UID2Nick($_GET["UIDs"])."<br>\n";
- echo "Bemerkung: Schicht eingetragen durch Erzengel ".$_SESSION['Nick']."<br>\n<br>\n";
- }
- else
- {
- echo "Es wird folgende Schicht wurde ". $_GET["eAnzahlNew"]. "x zus&auml;tzlich eingetragen:<br>\n";
- for( $i=0; $i<$_GET["eAnzahlNew"]; $i++)
- {
- echo "$i. <br>\n";
- $SQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`, `UID`, `Comment`) VALUES (";
- $SQL .= "'". $_GET["SID"]. "', '". $_GET["TID"]. "', '0', NULL)";
- $ERG = mysql_query($SQL, $con);
- if( $DEBUG )
- echo "DEBUG SQL: $SQL<br>\n";
- if ($ERG == 1)
- {
- echo "&Auml;nderung wurde gesichert...<br>";
- }
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)<br>";
- echo mysql_error($con);
- }
- echo "Es wird eine weitere Schicht eingetragen:<br><br>\n";
- }
- }
- break;
+ if( $_GET["UIDs"]>0)
+ {
+
+ $SQL = "SELECT * FROM `ShiftEntry` ".
+ "WHERE (`SID`='". $_GET["SID"]. "' AND `TID`='". $_GET["TID"]. "' AND `UID`='0')";
+ $ERG = mysql_query($SQL, $con);
+ if( mysql_num_rows($ERG) != 0 )
+ {
+ $chSQL = "UPDATE `ShiftEntry` SET ".
+ "`UID`='". $_GET["UIDs"]. "', `Comment`='shift added by ".$_SESSION['Nick']."' ".
+ "WHERE (`SID`='". $_GET["SID"]. "' AND ".
+ "`TID`='". $_GET["TID"]. "' AND `UID`='0' ) LIMIT 1";
+ }
+ else
+ {
+ $chSQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`, `UID`, `Comment`) VALUES (".
+ "'". $_GET["SID"]. "', '". $_GET["TID"]. "', ".
+ "'". $_GET["UIDs"]. "', 'shift added by ".$_SESSION['Nick']."')";
+ }
+ echo "Es wird folgende Schicht zus&auml;tzlich eingetragen:<br />\n";
+ echo "Engel: ".UID2Nick($_GET["UIDs"])."<br />\n";
+ echo "Bemerkung: Schicht eingetragen durch Erzengel ".$_SESSION['Nick']."<br />\n<br />\n";
+ }
+ else
+ {
+ echo "Es wird folgende Schicht wurde ". $_GET["eAnzahlNew"]. "x zus&auml;tzlich eingetragen:<br />\n";
+ for( $i=0; $i<$_GET["eAnzahlNew"]; $i++)
+ {
+ echo "$i. <br />\n";
+ $SQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`, `UID`, `Comment`) VALUES (";
+ $SQL .= "'". $_GET["SID"]. "', '". $_GET["TID"]. "', '0', NULL)";
+ $ERG = mysql_query($SQL, $con);
+ if( $debug )
+ echo "DEBUG SQL: $SQL<br />\n";
+ if ($ERG == 1)
+ {
+ echo "&Auml;nderung wurde gesichert...<br />";
+ }
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)<br />";
+ echo mysql_error($con);
+ }
+ echo "Es wird eine weitere Schicht eingetragen:<br /><br />\n";
+ }
+ }
+ break;
case 'engeldel':
- $chSQL = "UPDATE `ShiftEntry` SET `UID`='0', `Comment`= 'NULL' WHERE (`SID`='". $_GET["SID"].
- "' AND `UID`='". $_GET["UIDs"]. "') LIMIT 1";
- if( isset($_GET["freeloader"]) && $_GET["freeloader"]==1)
- {
- $sql = "SELECT * FROM `Shifts` WHERE (`SID` = '". $_GET["SID"]. "' )";
- $Erg = mysql_query($sql, $con);
- if( mysql_num_rows( $Erg) == 1)
- {
- $UID = $_GET["UIDs"];
- $Length = mysql_result($Erg, 0, "Len");
- $Comment = "Start: ". mysql_result($Erg, 0, "DateS"). "; ".
- "Beschreibung: ". mysql_result($Erg, 0, "Man"). "; ".
- "Removed by ". $_SESSION['Nick'];
- $ch2SQL =
- "INSERT INTO `ShiftFreeloader` (`Remove_Time`, `UID`, `Length`, `Comment`) ".
- "VALUES ( CURRENT_TIMESTAMP, '$UID', '$Length', '$Comment');";
- }
- }
- break;
+ $chSQL = "UPDATE `ShiftEntry` SET `UID`='0', `Comment`= 'NULL' WHERE (`SID`='". $_GET["SID"].
+ "' AND `UID`='". $_GET["UIDs"]. "') LIMIT 1";
+ if( isset($_GET["freeloader"]) && $_GET["freeloader"]==1)
+ {
+ $sql = "SELECT * FROM `Shifts` WHERE (`SID` = '". $_GET["SID"]. "' )";
+ $Erg = mysql_query($sql, $con);
+ if( mysql_num_rows( $Erg) == 1)
+ {
+ $UID = $_GET["UIDs"];
+ $Length = mysql_result($Erg, 0, "Len");
+ $Comment = "Start: ". mysql_result($Erg, 0, "DateS"). "; ".
+ "Beschreibung: ". mysql_result($Erg, 0, "Man"). "; ".
+ "Removed by ". $_SESSION['Nick'];
+ $ch2SQL =
+ "INSERT INTO `ShiftFreeloader` (`Remove_Time`, `UID`, `Length`, `Comment`) ".
+ "VALUES ( CURRENT_TIMESTAMP, '$UID', '$Length', '$Comment');";
+ }
+ }
+ break;
case 'engelshiftdel':
- $chSQL = "DELETE FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND `TID`='".
- $_GET["TID"]. "' AND `UID`='0' LIMIT 1";
- break;
+ $chSQL = "DELETE FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "' AND `TID`='".
+ $_GET["TID"]. "' AND `UID`='0' LIMIT 1";
+ break;
case 'changesave':
- $query = mysql_query("SELECT DATE_ADD('". $_GET["eDate"]. "', INTERVAL '+0 ". $_GET["eDauer"]. "' DAY_HOUR)", $con);
- $enddate = mysql_fetch_row($query);
-
- $chSQL = "UPDATE `Shifts` SET ".
- "`DateS`='". $_GET["eDate"]. "', ".
- "`DateE`='".$enddate[0]. "', ".
- "`RID`='". $_GET["eRID"]. "', ".
- "`Len`='". $_GET["eDauer"]. "', ".
- "`Man`='". $_GET["eName"]. "', ".
- "`URL`='". $_GET["eURL"]. "' ".
- "WHERE `SID`='". $_GET["SID"]. "'";
- SetHeaderGo2Back();
- break;
-
+ $query = mysql_query("SELECT DATE_ADD('". $_GET["eDate"]. "', INTERVAL '+0 ". $_GET["eDauer"]. "' DAY_HOUR)", $con);
+ $enddate = mysql_fetch_row($query);
+
+ $chSQL = "UPDATE `Shifts` SET ".
+ "`DateS`='". $_GET["eDate"]. "', ".
+ "`DateE`='".$enddate[0]. "', ".
+ "`RID`='". $_GET["eRID"]. "', ".
+ "`Len`='". $_GET["eDauer"]. "', ".
+ "`Man`='". $_GET["eName"]. "', ".
+ "`URL`='". $_GET["eURL"]. "' ".
+ "WHERE `SID`='". $_GET["SID"]. "'";
+ SetHeaderGo2Back();
+ break;
+
case 'delete':
- $chSQL = "DELETE FROM `Shifts` WHERE `SID`='". $_GET["SID"]. "' LIMIT 1";
- $ch2SQL = "DELETE FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "'";
- SetHeaderGo2Back();
- break;
+ $chSQL = "DELETE FROM `Shifts` WHERE `SID`='". $_GET["SID"]. "' LIMIT 1";
+ $ch2SQL = "DELETE FROM `ShiftEntry` WHERE `SID`='". $_GET["SID"]. "'";
+ SetHeaderGo2Back();
+ break;
case 'deleteShifs':
- foreach ($_GET as $k => $v)
- if( strpos( " ".$k, "SID") == 1)
- {
- echo "Shifts $v wird gelöscht...";
- executeSQL( "DELETE FROM `Shifts` WHERE `SID`='$v' LIMIT 1");
- echo "<br>\n";
- echo "ShiftEntry $v wird gelöscht...";
- executeSQL( "DELETE FROM `ShiftEntry` WHERE `SID`='$v'");
- echo "<br><br>\n";
- }
- break;
+ foreach ($_GET as $k => $v)
+ if( strpos( " ".$k, "SID") == 1)
+ {
+ echo "Shifts $v wird gelöscht...";
+ executeSQL( "DELETE FROM `Shifts` WHERE `SID`='$v' LIMIT 1");
+ echo "<br />\n";
+ echo "ShiftEntry $v wird gelöscht...";
+ executeSQL( "DELETE FROM `ShiftEntry` WHERE `SID`='$v'");
+ echo "<br /><br />\n";
+ }
+ break;
} // end switch
if (IsSet($chSQL)){
// echo $chSQL;
- // hier muesste das SQL ausgefuehrt werden...
- $Erg = mysql_query($chSQL, $con);
- if( $DEBUG )
- echo "DEBUG SQL: $chSQL<br>\n";
- if ($Erg == 1)
- {
- echo "&Auml;nderung wurde gesichert...<br>";
- if( $DEBUG )
- echo "DEBUG: ergebniss". $Erg. "<br>\n";
- if (IsSet($ch2SQL))
- {
- $Erg = mysql_query($ch2SQL, $con);
- if( $DEBUG )
- echo "DEBUG SQL: $ch2SQL<br>\n";
- if( $DEBUG ) echo "DEBUG: ergebniss". $Erg. "<br>\n";
- }
- }
- else
- {
- echo "Fehler beim speichern... bitte noch ein mal probieren :)<br>";
- echo mysql_error($con);
- }
+ // hier muesste das SQL ausgefuehrt werden...
+ $Erg = mysql_query($chSQL, $con);
+ if( $debug )
+ echo "DEBUG SQL: $chSQL<br />\n";
+ if ($Erg == 1)
+ {
+ echo "&Auml;nderung wurde gesichert...<br />";
+ if( $debug )
+ echo "DEBUG: ergebniss". $Erg. "<br />\n";
+ if (IsSet($ch2SQL))
+ {
+ $Erg = mysql_query($ch2SQL, $con);
+ if( $debug )
+ echo "DEBUG SQL: $ch2SQL<br />\n";
+ if( $debug ) echo "DEBUG: ergebniss". $Erg. "<br />\n";
+ }
+ }
+ else
+ {
+ echo "Fehler beim speichern... bitte noch ein mal probieren :)<br />";
+ echo mysql_error($con);
+ }
} // Ende Update
}
diff --git a/www-ssl/admin/schichtplan_druck.1.php b/www-ssl/admin/schichtplan_druck.1.php
index 30761390..30761390 100755..100644
--- a/www-ssl/admin/schichtplan_druck.1.php
+++ b/www-ssl/admin/schichtplan_druck.1.php
diff --git a/www-ssl/admin/schichtplan_druck.php b/www-ssl/admin/schichtplan_druck.php
index 23e65166..ef097043 100755..100644
--- a/www-ssl/admin/schichtplan_druck.php
+++ b/www-ssl/admin/schichtplan_druck.php
@@ -6,49 +6,49 @@ $submenus = 1;
if (!IsSet($_GET["action"]))
{
- include ("../../../camp2011/includes/header.php");
- include ("../../../camp2011/includes/funktionen.php");
- include ("../../../camp2011/includes/funktion_schichtplan_aray.php");
- include ("../../../camp2011/includes/funktion_schichtplan.php");
-
- echo "Hallo ". $_SESSION['Nick']. "<br>\n".
- "auf dieser Seite kannst du dir den Schichtplan in einer Druckansicht generieren lassen. W&auml;hle hierf&uuml;r ein Datum und den Raum:\n".
- "<br>\n";
-
- foreach( $VeranstaltungsTage as $k => $v)
- {
-
- $res = mysql_query("SELECT Name, RID FROM `Room` WHERE `show`!='N' ORDER BY `Name`;",$con);
- for ($i = 0; $i < mysql_num_rows($res); $i++)
- {
- $Tag = $VeranstaltungsTage[$k];
- $RID = mysql_result($res,$i,"RID");
- $Rname = mysql_result($res, $i, "Name");
- echo "\t<a href=\"./schichtplan_druck.php?action=1&Raum=$RID&ausdatum=$Tag\" target=\"_blank\">$Tag $Rname</a><br>\n";
- }
- echo "<br>\n";
- }
- echo "<br><br>";
-
- include ("../../../camp2011/includes/footer.php");
+ include ("../../../camp2011/includes/header.php");
+ include ("../../../camp2011/includes/funktionen.php");
+ include ("../../../camp2011/includes/funktion_schichtplan_aray.php");
+ include ("../../../camp2011/includes/funktion_schichtplan.php");
+
+ echo "Hallo ". $_SESSION['Nick']. "<br />\n".
+ "auf dieser Seite kannst du dir den Schichtplan in einer Druckansicht generieren lassen. W&auml;hle hierf&uuml;r ein Datum und den Raum:\n".
+ "<br />\n";
+
+ foreach( $VeranstaltungsTage as $k => $v)
+ {
+
+ $res = mysql_query("SELECT Name, RID FROM `Room` WHERE `show`!='N' ORDER BY `Name`;",$con);
+ for ($i = 0; $i < mysql_num_rows($res); $i++)
+ {
+ $Tag = $VeranstaltungsTage[$k];
+ $RID = mysql_result($res,$i,"RID");
+ $Rname = mysql_result($res, $i, "Name");
+ echo "\t<a href=\"./schichtplan_druck.php?action=1&Raum=$RID&ausdatum=$Tag\" target=\"_blank\">$Tag $Rname</a><br />\n";
+ }
+ echo "<br />\n";
+ }
+ echo "<br /><br />";
+
+ include ("../../../camp2011/includes/footer.php");
}
-else //#################################################################
+else //#################################################################
{
if (IsSet($_GET["Raum"]) AND IsSet($_GET["ausdatum"]))
- {
- $Raum = $_GET["Raum"];
- $ausdatum = $_GET["ausdatum"];
-
- include ("../../../camp2011/includes/config_db.php");
- include ("../../../camp2011/includes/config.php");
- include ("../../../camp2011/includes/secure.php");
- //var wird nur gesetzt immer edit auszublenden, achtung sesion darf nicht gestart sein !!!
- $_SESSION['CVS'][ "admin/schichtplan.php" ] = "N";
- include ("../../../camp2011/includes/funktion_lang.php");
- include ("../../../camp2011/includes/funktion_schichtplan.php");
- include ("../../../camp2011/includes/funktion_schichtplan_aray.php");
- include ("../../../camp2011/includes/funktion_user.php");
- ?>
+ {
+ $Raum = $_GET["Raum"];
+ $ausdatum = $_GET["ausdatum"];
+
+ include ("../../../camp2011/includes/config_db.php");
+ include ("../../../camp2011/includes/config.php");
+ include ("../../../camp2011/includes/secure.php");
+ //var wird nur gesetzt immer edit auszublenden, achtung sesion darf nicht gestart sein !!!
+ $_SESSION['CVS'][ "admin/schichtplan.php" ] = "N";
+ include ("../../../camp2011/includes/funktion_lang.php");
+ include ("../../../camp2011/includes/funktion_schichtplan.php");
+ include ("../../../camp2011/includes/funktion_schichtplan_aray.php");
+ include ("../../../camp2011/includes/funktion_user.php");
+ ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
@@ -67,55 +67,55 @@ else //#################################################################
<h1>Schichtplan</h1>
<table>
- <tr>
- <td width="250" align="left">
- <span style="font-weight:bold;font-size:100%">Datum:</span>
- <span style="font-weight:bold;font-size:200%"><?PHP echo $ausdatum; ?></span>
- </td>
- <td width="350" align="right">
- <span style="font-weight:bold;font-size:100%">Raum:</span>
- <span style="font-weight:bold;font-size:200%"><?PHP echo $RoomID[$Raum]; ?> </span>
- </td>
- </tr>
+ <tr>
+ <td width="250" align="left">
+ <span style="font-weight:bold;font-size:100%">Datum:</span>
+ <span style="font-weight:bold;font-size:200%"><?php echo $ausdatum; ?></span>
+ </td>
+ <td width="350" align="right">
+ <span style="font-weight:bold;font-size:100%">Raum:</span>
+ <span style="font-weight:bold;font-size:200%"><?php echo $RoomID[$Raum]; ?> </span>
+ </td>
+ </tr>
</table>
<table border="2" width="650" class="border" cellpadding="2" cellspacing="1">
<!--Ausgabe Spalten überschrift-->
- <tr class="contenttopic">
- <th bgcolor="#E0E0E0">Uhrzeit</th>
- <th bgcolor="#E0E0E0">Schichtplanbelegung</th>
- </tr>
-<?PHP
+ <tr class="contenttopic">
+ <th bgcolor="#E0E0E0">Uhrzeit</th>
+ <th bgcolor="#E0E0E0">Schichtplanbelegung</th>
+ </tr>
+<?php
//Zeit Ausgeben
for( $i = 0; $i < 24; $i++ )
- for( $j = 0; $j < $GlobalZeileProStunde; $j++)
- {
- $Spalten[$i * $GlobalZeileProStunde + $j] =
- "\t<tr class=\"content\">\n";
- if( $j==0)
- {
- $Spalten[$i * $GlobalZeileProStunde + $j].=
- "\t\t<td rowspan=\"$GlobalZeileProStunde\">";
- if( $i < 10 )
- $Spalten[$i * $GlobalZeileProStunde + $j].= "0";
- $Spalten[$i * $GlobalZeileProStunde + $j].= "$i:";
- if( ( ($j*60) / $GlobalZeileProStunde) < 10 )
- $Spalten[$i * $GlobalZeileProStunde + $j].= "0";
- $Spalten[$i * $GlobalZeileProStunde + $j].=
- ( ($j*60) / $GlobalZeileProStunde). "</td>\n";
-
- }
- }
+ for( $j = 0; $j < $GlobalZeileProStunde; $j++)
+ {
+ $Spalten[$i * $GlobalZeileProStunde + $j] =
+ "\t<tr class=\"content\">\n";
+ if( $j==0)
+ {
+ $Spalten[$i * $GlobalZeileProStunde + $j].=
+ "\t\t<td rowspan=\"$GlobalZeileProStunde\">";
+ if( $i < 10 )
+ $Spalten[$i * $GlobalZeileProStunde + $j].= "0";
+ $Spalten[$i * $GlobalZeileProStunde + $j].= "$i:";
+ if( ( ($j*60) / $GlobalZeileProStunde) < 10 )
+ $Spalten[$i * $GlobalZeileProStunde + $j].= "0";
+ $Spalten[$i * $GlobalZeileProStunde + $j].=
+ ( ($j*60) / $GlobalZeileProStunde). "</td>\n";
+
+ }
+ }
CreateRoomShifts( $Raum );
// Ausgabe Zeilen
- for ($i = 0; $i < (24 * $GlobalZeileProStunde); $i++) echo $Spalten[$i];
+ for ($i = 0; $i < (24 * $GlobalZeileProStunde); $i++) echo $Spalten[$i];
// Ende
echo "</table>\n";
diff --git a/www-ssl/admin/shiftadd.php b/www-ssl/admin/shiftadd.php
index 7c64543f..34c248fa 100755..100644
--- a/www-ssl/admin/shiftadd.php
+++ b/www-ssl/admin/shiftadd.php
@@ -6,61 +6,61 @@ include ("../../../camp2011/includes/header.php");
$Time = time()+3600+3600;
-echo "Hallo ".$_SESSION['Nick'].",<br>\n";
+echo "Hallo ".$_SESSION['Nick'].",<br />\n";
// erstellt ein Array der Reume
- $sql = "SELECT `RID`, `Name` FROM `Room` ORDER BY `Name`";
- $Erg = mysql_query($sql, $con);
- $rowcount = mysql_num_rows($Erg);
+ $sql = "SELECT `RID`, `Name` FROM `Room` ORDER BY `Name`";
+ $Erg = mysql_query($sql, $con);
+ $rowcount = mysql_num_rows($Erg);
- for ($i=0; $i<$rowcount; $i++)
- {
- $Room[$i]["RID"] = mysql_result($Erg, $i, "RID");
- $Room[$i]["Name"] = mysql_result($Erg, $i, "Name");
- }
+ for ($i=0; $i<$rowcount; $i++)
+ {
+ $Room[$i]["RID"] = mysql_result($Erg, $i, "RID");
+ $Room[$i]["Name"] = mysql_result($Erg, $i, "Name");
+ }
// erstellt ein Aray der Engeltypen
- $sql = "SELECT `TID`, `Name` FROM `EngelType` ORDER BY `Name`";
- $Erg = mysql_query($sql, $con);
- $rowcount = mysql_num_rows($Erg);
+ $sql = "SELECT `TID`, `Name` FROM `EngelType` ORDER BY `Name`";
+ $Erg = mysql_query($sql, $con);
+ $rowcount = mysql_num_rows($Erg);
- for ($i=0; $i<$rowcount; $i++)
- {
- $EngelType[$i]["TID"] = mysql_result($Erg, $i, "TID");
- $EngelType[$i]["Name"] = mysql_result($Erg, $i, "Name").Get_Text("inc_schicht_engel");
- }
+ for ($i=0; $i<$rowcount; $i++)
+ {
+ $EngelType[$i]["TID"] = mysql_result($Erg, $i, "TID");
+ $EngelType[$i]["Name"] = mysql_result($Erg, $i, "Name").Get_Text("inc_schicht_engel");
+ }
// sesion mit stanadrt werten befüllen
if( !isset( $_SESSION['shiftadd.php']['SchichtName']))
{
- $_SESSION['shiftadd.php']['SchichtName'] = "--???--";
- $_SESSION['shiftadd.php']['RID'] = "";
- $_SESSION['shiftadd.php']['MonthJahr'] = gmdate("Y-m", $Time);
- $_SESSION['shiftadd.php']['SDatum'] = gmdate("d", $Time);
- $_SESSION['shiftadd.php']['STime'] = "10";
- $_SESSION['shiftadd.php']['MoreThenOne'] = "ON";
- $_SESSION['shiftadd.php']['EDatum'] = gmdate("d", $Time);
- $_SESSION['shiftadd.php']['ETime'] = "12";
- $_SESSION['shiftadd.php']['len'] = "2";
- $_SESSION['shiftadd.php']['NachtON'] = "OFF";
- $_SESSION['shiftadd.php']['len_night'] = "00-04-08-10-12-14-16-18-20-22-24";
+ $_SESSION['shiftadd.php']['SchichtName'] = "--???--";
+ $_SESSION['shiftadd.php']['RID'] = "";
+ $_SESSION['shiftadd.php']['MonthJahr'] = gmdate("Y-m", $Time);
+ $_SESSION['shiftadd.php']['SDatum'] = gmdate("d", $Time);
+ $_SESSION['shiftadd.php']['STime'] = "10";
+ $_SESSION['shiftadd.php']['MoreThenOne'] = "ON";
+ $_SESSION['shiftadd.php']['EDatum'] = gmdate("d", $Time);
+ $_SESSION['shiftadd.php']['ETime'] = "12";
+ $_SESSION['shiftadd.php']['len'] = "2";
+ $_SESSION['shiftadd.php']['NachtON'] = "OFF";
+ $_SESSION['shiftadd.php']['len_night'] = "00-04-08-10-12-14-16-18-20-22-24";
}
// wenn werte übergeben in sesion eintragen
if( !isset($_GET["NachtON"]))
- $_GET["NachtON"] = "OFF";
+ $_GET["NachtON"] = "OFF";
if( !isset($_GET["MoreThenOne"]))
- $_GET["MoreThenOne"] = "OFF";
+ $_GET["MoreThenOne"] = "OFF";
if( isset( $_GET["SchichtName"]))
{
- foreach ($_GET as $k => $v)
- {
- $_SESSION['shiftadd.php'][$k] = $v;
- }
+ foreach ($_GET as $k => $v)
+ {
+ $_SESSION['shiftadd.php'][$k] = $v;
+ }
}
if (!IsSet($_GET["action"]))
- $_GET["action"] = "new";
+ $_GET["action"] = "new";
switch( $_GET["action"])
{
@@ -70,187 +70,187 @@ Hier kannst du neue Schichten eintragen. Dazu musst du den Anfang und das Ende d
&Uuml;ber die L&auml;nge der Schichten errechnet sich dadurch die Anzahl dieser. Dadurch k&ouml;nnen gleich
mehrere Schichten auf einmal erfasst werden:
-<form action="<?PHP echo $_SERVER['SCRIPT_NAME']; ?>" >
+<form action="<?php echo $_SERVER['SCRIPT_NAME']; ?>" >
<table>
<tr>
<td align="right">Name:</td>
- <td><input type="text" name="SchichtName" size="50" value="<?PHP echo $_SESSION["shiftadd.php"]["SchichtName"]; ?>"></td>
+ <td><input type="text" name="SchichtName" size="50" value="<?php echo $_SESSION["shiftadd.php"]["SchichtName"]; ?>"></td>
</tr>
<tr>
<td align="right">Ort:</td>
<td><select name="RID">
-<?PHP
- foreach ($Room As $RTemp)
- {
- echo "\t<option value=\"". $RTemp["RID"]. "\"";
- if( $RTemp["RID"] == $_SESSION["shiftadd.php"]["RID"])
- echo " SELECTED";
- echo ">". $RTemp["Name"]. "</option>\n";
- }
- ?>
+<?php
+ foreach ($Room As $RTemp)
+ {
+ echo "\t<option value=\"". $RTemp["RID"]. "\"";
+ if( $RTemp["RID"] == $_SESSION["shiftadd.php"]["RID"])
+ echo " SELECTED";
+ echo ">". $RTemp["Name"]. "</option>\n";
+ }
+ ?>
</select></td>
</tr>
<tr><td><u>Zeit:</u></td></tr>
<tr>
<td align="right">Month.Jahr:</td>
- <td><input type="ext" name="MonthJahr" size="7" value="<?PHP echo $_SESSION["shiftadd.php"]["MonthJahr"]; ?>"></td>
+ <td><input type="ext" name="MonthJahr" size="7" value="<?php echo $_SESSION["shiftadd.php"]["MonthJahr"]; ?>"></td>
</tr>
<tr>
<td align="right">Beginn:</td>
- <td>Date<input type="text" name="SDatum" size="5" value="<?PHP echo $_SESSION["shiftadd.php"]["SDatum"]; ?>">
- Time<input type="text" name="STime" size="5" value="<?PHP echo $_SESSION["shiftadd.php"]["STime"]; ?>"></td>
+ <td>Date<input type="text" name="SDatum" size="5" value="<?php echo $_SESSION["shiftadd.php"]["SDatum"]; ?>">
+ Time<input type="text" name="STime" size="5" value="<?php echo $_SESSION["shiftadd.php"]["STime"]; ?>"></td>
</tr>
<tr>
<td align="right">More then One</td>
- <td><input type="checkbox" name="MoreThenOne" value="ON" <?PHP
- if( $_SESSION["shiftadd.php"]["MoreThenOne"]=="ON")
- echo " CHECKED";
- ?>></td>
+ <td><input type="checkbox" name="MoreThenOne" value="ON" <?php
+ if( $_SESSION["shiftadd.php"]["MoreThenOne"]=="ON")
+ echo " CHECKED";
+ ?>></td>
</tr>
<tr>
<td align="right">End:</td>
- <td>Date<input type="text" name="EDatum" size="5" value="<?PHP echo $_SESSION["shiftadd.php"]["EDatum"]; ?>">
- Time<input type="text" name="ETime" size="5" value="<?PHP echo $_SESSION["shiftadd.php"]["ETime"]; ?>"></td>
+ <td>Date<input type="text" name="EDatum" size="5" value="<?php echo $_SESSION["shiftadd.php"]["EDatum"]; ?>">
+ Time<input type="text" name="ETime" size="5" value="<?php echo $_SESSION["shiftadd.php"]["ETime"]; ?>"></td>
</tr>
<tr>
<td align="right">L&auml;nge in h:</td>
- <td><input type="text" name="len" size="5" value="<?PHP echo $_SESSION["shiftadd.php"]["len"]; ?>"></td>
+ <td><input type="text" name="len" size="5" value="<?php echo $_SESSION["shiftadd.php"]["len"]; ?>"></td>
</tr>
<tr>
<td align="right">Sonderschichten ein:</td>
- <td><input type="checkbox" name="NachtON" value="ON" <?PHP
- if($_SESSION["shiftadd.php"]["NachtON"]=="ON")
- echo " CHECKED";
- ?>></td>
+ <td><input type="checkbox" name="NachtON" value="ON" <?php
+ if($_SESSION["shiftadd.php"]["NachtON"]=="ON")
+ echo " CHECKED";
+ ?>></td>
</tr>
<tr>
<td align="right">Sonder in h (Time;Time):</td>
- <td><input type="text" name="len_night" size="50" value="<?PHP echo $_SESSION["shiftadd.php"]["len_night"]; ?>"></td>
+ <td><input type="text" name="len_night" size="50" value="<?php echo $_SESSION["shiftadd.php"]["len_night"]; ?>"></td>
</tr>
<tr><td><u>Anzahl Engel je Type:</u></td></tr>
-<?PHP
- foreach ($EngelType As $TTemp)
- {
- echo " <tr><td align=\"right\">". $TTemp["Name"]. ":</td>\n";
- echo " <td><input type=\"text\" name=\"EngelType". $TTemp["TID"]. "\" size=\"5\" value=\"";
- if( isset($_SESSION["shiftadd.php"][ "EngelType". $TTemp["TID"] ]))
- echo $_SESSION["shiftadd.php"][ "EngelType". $TTemp["TID"] ];
- else
- echo "0";
- echo "\"></td>\n";
- }
+<?php
+ foreach ($EngelType As $TTemp)
+ {
+ echo " <tr><td align=\"right\">". $TTemp["Name"]. ":</td>\n";
+ echo " <td><input type=\"text\" name=\"EngelType". $TTemp["TID"]. "\" size=\"5\" value=\"";
+ if( isset($_SESSION["shiftadd.php"][ "EngelType". $TTemp["TID"] ]))
+ echo $_SESSION["shiftadd.php"][ "EngelType". $TTemp["TID"] ];
+ else
+ echo "0";
+ echo "\"></td>\n";
+ }
?>
</table>
- <br>
+ <br />
<input type="hidden" name="OnlyShow" value="ON">
<input type="hidden" name="action" value="newsave">
<input type="submit" value="zeig mal Gabriel!">
</form>
-<?PHP
- break; // Ende new
+<?php
+ break; // Ende new
case 'newsave':
if (isset($_GET["SDatum"]) && ($_GET["len"] > 0))
{
- $lenOrg = $_GET["len"];
- if( $_GET["NachtON"] == "ON" )
- {
- $lenArrayDummy = explode( "-", $_GET["len_night"]);
+ $lenOrg = $_GET["len"];
+ if( $_GET["NachtON"] == "ON" )
+ {
+ $lenArrayDummy = explode( "-", $_GET["len_night"]);
foreach ( $lenArrayDummy as $Temp )
{
- if( isset($Temp2) )
- $lenArray[intval($Temp2)] = intval($Temp)-intval($Temp2);
- $Temp2 = $Temp;
- }//foreach
- }//IF( $NachtON == "ON" )
-
- echo "<table border=\"1\">\n";
- echo "<tr>\n";
- echo "\t<td valign=\"top\" align=\"center\">Start</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">End</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">len</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">RID</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">Beschreibung</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">Entry 'Shifts'</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">SID</td>\n";
- echo "\t<td valign=\"top\" align=\"center\">Entrys</td>\n";
- echo "</tr>\n";
-
- $DateEnd = $_GET["SDatum"];
- $TimeEnd = intval($_GET["STime"]);
- $len=0;
- do
- {
- // define Start time
- $Date = $DateEnd;
- $Time = $TimeEnd;
- $_DateS = $_GET["MonthJahr"]. "-". $Date. " ". $Time. ":00:00";
-
- // define End time
- if( $_GET["NachtON"] == "ON" )
- {
- if( !isset($lenArray[$Time])) die("Zeit $Time h nicht definiert.");
- $_GET["len"] = $lenArray[$Time];
- if( $_GET["len"]<1) die("len <1");
- }
- $TimeEnd = $Time+ $_GET["len"];
-
- //Tagesüberschreitung
- while( $TimeEnd >= 24 )
- {
- $TimeEnd -= 24;
- $DateEnd += 1;
- }
- //ist schischt zu lang dan verkürzen
- if( $DateEnd > $_GET["EDatum"] || ($DateEnd == $_GET["EDatum"] && $TimeEnd >= $_GET["ETime"]) )
- {
- $_GET["len"] -= ($DateEnd- $_GET["EDatum"])*24;
- $_GET["len"] -= ($TimeEnd- $_GET["ETime"]); // -(-) ->> +
- $DateEnd = $_GET["EDatum"];
- $TimeEnd = $_GET["ETime"];
- }
- $_DateE = $_GET["MonthJahr"]. "-". $DateEnd. " ". $TimeEnd. ":00:00";
-
- if( $_DateS != $_DateE )
- CreateNewEntry();
-
- if( $_GET["MoreThenOne"]!="ON" ) break;
- if( $DateEnd >= $_GET["EDatum"] && $TimeEnd >= intval($_GET["ETime"]) ) break;
- } while( true );
- echo "</table>";
-
- if( $_GET["OnlyShow"]=="ON" )
- {
- echo "<form action=\"". $_SERVER['SCRIPT_NAME']. "\">";
- echo "\n\t<Input type=\"hidden\" name=\"SchichtName\" value=\"". $_GET["SchichtName"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"MonthJahr\" value=\"". $_GET["MonthJahr"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"SDatum\" value=\"". $_GET["SDatum"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"STime\" value=\"". $_GET["STime"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"MoreThenOne\" value=\"". $_GET["MoreThenOne"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"EDatum\" value=\"". $_GET["EDatum"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"ETime\" value=\"". $_GET["ETime"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"len\" value=\"". $lenOrg. "\">";
- echo "\n\t<input type=\"hidden\" name=\"RID\" value=\"". $_GET["RID"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"NachtON\" value=\"". $_GET["NachtON"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"len_night\" value=\"". $_GET["len_night"]. "\">";
- echo "\n\t<input type=\"hidden\" name=\"OnlyShow\" value=\"OFF\">";
- foreach ($EngelType As $TTemp)
- {
- $Temp = "EngelType".$TTemp["TID"];
- echo "\n\t<input type=\"hidden\" name=\"". $Temp. "\" value=\"". $_GET[$Temp]. "\">";
- }
- echo "\n\t<input type=\"hidden\" name=\"action\" value=\"newsave\">";
- echo "\n\t<input type=\"submit\" value=\"mach mal Gabriel!\">";
- echo "\n</form>";
- } //if
+ if( isset($Temp2) )
+ $lenArray[intval($Temp2)] = intval($Temp)-intval($Temp2);
+ $Temp2 = $Temp;
+ }//foreach
+ }//IF( $NachtON == "ON" )
+
+ echo "<table border=\"1\">\n";
+ echo "<tr>\n";
+ echo "\t<td valign=\"top\" align=\"center\">Start</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">End</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">len</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">RID</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">Beschreibung</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">Entry 'Shifts'</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">SID</td>\n";
+ echo "\t<td valign=\"top\" align=\"center\">Entrys</td>\n";
+ echo "</tr>\n";
+
+ $DateEnd = $_GET["SDatum"];
+ $TimeEnd = intval($_GET["STime"]);
+ $len=0;
+ do
+ {
+ // define Start time
+ $Date = $DateEnd;
+ $Time = $TimeEnd;
+ $_DateS = $_GET["MonthJahr"]. "-". $Date. " ". $Time. ":00:00";
+
+ // define End time
+ if( $_GET["NachtON"] == "ON" )
+ {
+ if( !isset($lenArray[$Time])) die("Zeit $Time h nicht definiert.");
+ $_GET["len"] = $lenArray[$Time];
+ if( $_GET["len"]<1) die("len <1");
+ }
+ $TimeEnd = $Time+ $_GET["len"];
+
+ //Tagesüberschreitung
+ while( $TimeEnd >= 24 )
+ {
+ $TimeEnd -= 24;
+ $DateEnd += 1;
+ }
+ //ist schischt zu lang dan verkürzen
+ if( $DateEnd > $_GET["EDatum"] || ($DateEnd == $_GET["EDatum"] && $TimeEnd >= $_GET["ETime"]) )
+ {
+ $_GET["len"] -= ($DateEnd- $_GET["EDatum"])*24;
+ $_GET["len"] -= ($TimeEnd- $_GET["ETime"]); // -(-) ->> +
+ $DateEnd = $_GET["EDatum"];
+ $TimeEnd = $_GET["ETime"];
+ }
+ $_DateE = $_GET["MonthJahr"]. "-". $DateEnd. " ". $TimeEnd. ":00:00";
+
+ if( $_DateS != $_DateE )
+ CreateNewEntry();
+
+ if( $_GET["MoreThenOne"]!="ON" ) break;
+ if( $DateEnd >= $_GET["EDatum"] && $TimeEnd >= intval($_GET["ETime"]) ) break;
+ } while( true );
+ echo "</table>";
+
+ if( $_GET["OnlyShow"]=="ON" )
+ {
+ echo "<form action=\"". $_SERVER['SCRIPT_NAME']. "\">";
+ echo "\n\t<Input type=\"hidden\" name=\"SchichtName\" value=\"". $_GET["SchichtName"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"MonthJahr\" value=\"". $_GET["MonthJahr"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"SDatum\" value=\"". $_GET["SDatum"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"STime\" value=\"". $_GET["STime"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"MoreThenOne\" value=\"". $_GET["MoreThenOne"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"EDatum\" value=\"". $_GET["EDatum"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"ETime\" value=\"". $_GET["ETime"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"len\" value=\"". $lenOrg. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"RID\" value=\"". $_GET["RID"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"NachtON\" value=\"". $_GET["NachtON"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"len_night\" value=\"". $_GET["len_night"]. "\">";
+ echo "\n\t<input type=\"hidden\" name=\"OnlyShow\" value=\"OFF\">";
+ foreach ($EngelType As $TTemp)
+ {
+ $Temp = "EngelType".$TTemp["TID"];
+ echo "\n\t<input type=\"hidden\" name=\"". $Temp. "\" value=\"". $_GET[$Temp]. "\">";
+ }
+ echo "\n\t<input type=\"hidden\" name=\"action\" value=\"newsave\">";
+ echo "\n\t<input type=\"submit\" value=\"mach mal Gabriel!\">";
+ echo "\n</form>";
+ } //if
} //IF
break;
case 'engeldel':
- break;
+ break;
} // end switch
@@ -258,100 +258,100 @@ case 'engeldel':
function CreateNewEntry()
{
- global $con, $_DateS, $_DateE, $EngelType, $DEBUG;
- foreach ($EngelType As $TTemp)
- {
- $Temp = "EngelType".$TTemp["TID"];
- global $$Temp;
- }
-
- echo "<tr>\n";
-
- echo "\t<td>$_DateS</td>\n";
- echo "\t<td>$_DateE</td>\n";
- echo "\t<td>". $_GET["len"]. "</td>\n";
- echo "\t<td>". $_GET["RID"]. "</td>\n";
- echo "\t<td>". $_GET["SchichtName"]. "</td>\n";
-
-
- // Ist eintarg schon vorhanden?
- $SQL = "SELECT `SID` FROM `Shifts` ";
- $SQL .= "WHERE (".
- "`DateS` = '". $_DateS. "' AND ".
- "`DateE` = '". $_DateE. "' AND ".
- "`RID` = '". $_GET["RID"]. "');";
- $Erg = mysql_query($SQL, $con);
-
- if( mysql_num_rows($Erg) != 0 )
- echo "\t<td>exists</td>";
- elseif( $_GET["OnlyShow"] == "OFF" )
- {
- // erstellt Eintrag in Shifts für die algemeine schicht
- $SQL = "INSERT INTO `Shifts` ( `DateS`, `DateE`, `Len`, `RID`, `Man`) VALUES ( ";
- $SQL .= "'". $_DateS. "', '". $_DateE. "', ";
- $SQL .= "'". $_GET["len"]. "', '". $_GET["RID"]. "', ";
- $SQL .= "'". $_GET["SchichtName"]. "');";
- $Erg = db_query($SQL, "create shift");
-
- $SQLFail = "\n\t<br>[".$SQL. "]";
-
- if ($Erg == 1) echo "\t<td>pass</td>\n";
- else echo "\t<td>fail <br>\n<u>". mysql_error($con). "</u>$SQLFail</td>\n";
-
- } else
- echo "\t<td>only show</td>\n";
-
- // sucht SID von eingetragennen schiten
- $SQL = "SELECT SID FROM `Shifts` ";
- $SQL .= "WHERE (".
- "`DateS` = '". $_DateS. "' AND ".
- "`DateE` = '". $_DateE. "' AND ".
- "`Len` = '". $_GET["len"]. "' AND ".
- "`RID` = '". $_GET["RID"]. "');";
- $Erg = mysql_query($SQL, $con);
- if( mysql_num_rows($Erg) == 0 )
- echo "\t<td>?</td>";
- else
- {
- $SID = mysql_result($Erg, 0, "SID");
- echo "\t<td>". $SID. "</td>";
- }
-
- // erstellt für jeden Engeltypen die eintrage in 'ShiftEntry'
- echo "\t<td>";
- foreach ($EngelType As $TTemp)
- {
- $Temp = "EngelType".$TTemp["TID"];
-
- if( $_GET[$Temp] > 0 )
- {
- $i = 0;
- echo $_GET[$Temp]. " ".$TTemp["Name"]. "<br>\t";
- while( $i++ < $_GET[$Temp] )
- {
- if( $_GET["OnlyShow"] == "OFF" )
- {
- $SQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`) VALUES (";
- $SQL .= "'". $SID. "', ";
- $SQL .= "'". $TTemp["TID"]. "');";
-
- $Erg = mysql_query($SQL, $con);
-
- if( $DEBUG ) $SQLFail = "\n\t<br>[".$SQL. "]";
-
- if ($Erg == 1) echo "'pass' ";
- else echo "'fail' <u>". mysql_error($con). "</u>$SQLFail</td>\n";
-
- }
- else
- echo "+";
- }
- echo "<br>";
- } // IF $$TEMP
- } // FOREACH
- echo "</td>";
-
- echo "</tr>\n";
+ global $con, $_DateS, $_DateE, $EngelType, $debug;
+ foreach ($EngelType As $TTemp)
+ {
+ $Temp = "EngelType".$TTemp["TID"];
+ global $$Temp;
+ }
+
+ echo "<tr>\n";
+
+ echo "\t<td>$_DateS</td>\n";
+ echo "\t<td>$_DateE</td>\n";
+ echo "\t<td>". $_GET["len"]. "</td>\n";
+ echo "\t<td>". $_GET["RID"]. "</td>\n";
+ echo "\t<td>". $_GET["SchichtName"]. "</td>\n";
+
+
+ // Ist eintarg schon vorhanden?
+ $SQL = "SELECT `SID` FROM `Shifts` ";
+ $SQL .= "WHERE (".
+ "`DateS` = '". $_DateS. "' AND ".
+ "`DateE` = '". $_DateE. "' AND ".
+ "`RID` = '". $_GET["RID"]. "');";
+ $Erg = mysql_query($SQL, $con);
+
+ if( mysql_num_rows($Erg) != 0 )
+ echo "\t<td>exists</td>";
+ elseif( $_GET["OnlyShow"] == "OFF" )
+ {
+ // erstellt Eintrag in Shifts für die algemeine schicht
+ $SQL = "INSERT INTO `Shifts` ( `DateS`, `DateE`, `Len`, `RID`, `Man`) VALUES ( ";
+ $SQL .= "'". $_DateS. "', '". $_DateE. "', ";
+ $SQL .= "'". $_GET["len"]. "', '". $_GET["RID"]. "', ";
+ $SQL .= "'". $_GET["SchichtName"]. "');";
+ $Erg = db_query($SQL, "create shift");
+
+ $SQLFail = "\n\t<br />[".$SQL. "]";
+
+ if ($Erg == 1) echo "\t<td>pass</td>\n";
+ else echo "\t<td>fail <br />\n<u>". mysql_error($con). "</u>$SQLFail</td>\n";
+
+ } else
+ echo "\t<td>only show</td>\n";
+
+ // sucht SID von eingetragennen schiten
+ $SQL = "SELECT SID FROM `Shifts` ";
+ $SQL .= "WHERE (".
+ "`DateS` = '". $_DateS. "' AND ".
+ "`DateE` = '". $_DateE. "' AND ".
+ "`Len` = '". $_GET["len"]. "' AND ".
+ "`RID` = '". $_GET["RID"]. "');";
+ $Erg = mysql_query($SQL, $con);
+ if( mysql_num_rows($Erg) == 0 )
+ echo "\t<td>?</td>";
+ else
+ {
+ $SID = mysql_result($Erg, 0, "SID");
+ echo "\t<td>". $SID. "</td>";
+ }
+
+ // erstellt für jeden Engeltypen die eintrage in 'ShiftEntry'
+ echo "\t<td>";
+ foreach ($EngelType As $TTemp)
+ {
+ $Temp = "EngelType".$TTemp["TID"];
+
+ if( $_GET[$Temp] > 0 )
+ {
+ $i = 0;
+ echo $_GET[$Temp]. " ".$TTemp["Name"]. "<br />\t";
+ while( $i++ < $_GET[$Temp] )
+ {
+ if( $_GET["OnlyShow"] == "OFF" )
+ {
+ $SQL = "INSERT INTO `ShiftEntry` (`SID`, `TID`) VALUES (";
+ $SQL .= "'". $SID. "', ";
+ $SQL .= "'". $TTemp["TID"]. "');";
+
+ $Erg = mysql_query($SQL, $con);
+
+ if( $debug ) $SQLFail = "\n\t<br />[".$SQL. "]";
+
+ if ($Erg == 1) echo "'pass' ";
+ else echo "'fail' <u>". mysql_error($con). "</u>$SQLFail</td>\n";
+
+ }
+ else
+ echo "+";
+ }
+ echo "<br />";
+ } // IF $$TEMP
+ } // FOREACH
+ echo "</td>";
+
+ echo "</tr>\n";
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/sprache.php b/www-ssl/admin/sprache.php
index 050b0736..ebf1db32 100755..100644
--- a/www-ssl/admin/sprache.php
+++ b/www-ssl/admin/sprache.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Sprache";
$header = "Liste der existierenden Sprcheintr&auml;ge";
@@ -7,114 +7,114 @@ include ("../../../camp2011/includes/header.php");
if( !isset( $_GET["TextID"] ) )
{
- echo Get_Text("Hello").$_SESSION['Nick'].", <br>\n";
- echo Get_Text("pub_sprache_text1")."<br><br>\n";
+ echo Get_Text("Hello").$_SESSION['Nick'].", <br />\n";
+ echo Get_Text("pub_sprache_text1")."<br /><br />\n";
- echo "<a href=\"?ShowEntry=y\">". Get_Text("pub_sprache_ShowEntry"). "</a>";
- // ausgabe Tabellenueberschift
- $SQL_Sprachen = "SELECT `Sprache` FROM `Sprache` GROUP BY `Sprache`;";
- $erg_Sprachen = mysql_query($SQL_Sprachen, $con);
- echo mysql_error($con);
-
- for( $i=0; $i<mysql_num_rows( $erg_Sprachen ); $i++ )
- $Sprachen[mysql_result( $erg_Sprachen, $i, "Sprache" )] = $i;
+ echo "<a href=\"?ShowEntry=y\">". Get_Text("pub_sprache_ShowEntry"). "</a>";
+ // ausgabe Tabellenueberschift
+ $SQL_Sprachen = "SELECT `Sprache` FROM `Sprache` GROUP BY `Sprache`;";
+ $erg_Sprachen = mysql_query($SQL_Sprachen, $con);
+ echo mysql_error($con);
+
+ for( $i=0; $i<mysql_num_rows( $erg_Sprachen ); $i++ )
+ $Sprachen[mysql_result( $erg_Sprachen, $i, "Sprache" )] = $i;
- echo "\t<table border=\"0\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n\t\t<tr>";
- echo "\t\t<td class=\"contenttopic\"><b>". Get_Text("pub_sprache_TextID"). "</b></td>";
- foreach( $Sprachen as $Name => $Value )
- echo "<td class=\"contenttopic\"><b>".
- Get_Text("pub_sprache_Sprache"). " ". $Name.
- "</b></td>";
- echo "\t\t<td class=\"contenttopic\"><b>". Get_Text("pub_sprache_Edit"). "</b></td>";
- echo "\t\t</tr>";
+ echo "\t<table border=\"0\" class=\"border\" cellpadding=\"2\" cellspacing=\"1\">\n\t\t<tr>";
+ echo "\t\t<td class=\"contenttopic\"><b>". Get_Text("pub_sprache_TextID"). "</b></td>";
+ foreach( $Sprachen as $Name => $Value )
+ echo "<td class=\"contenttopic\"><b>".
+ Get_Text("pub_sprache_Sprache"). " ". $Name.
+ "</b></td>";
+ echo "\t\t<td class=\"contenttopic\"><b>". Get_Text("pub_sprache_Edit"). "</b></td>";
+ echo "\t\t</tr>";
- if( isset($_GET["ShowEntry"]))
- {
- // ausgabe eintraege
- $SQL = "SELECT * FROM `Sprache` ORDER BY `TextID`;";
- $erg = mysql_query($SQL, $con);
- echo mysql_error($con);
+ if( isset($_GET["ShowEntry"]))
+ {
+ // ausgabe eintraege
+ $SQL = "SELECT * FROM `Sprache` ORDER BY `TextID`;";
+ $erg = mysql_query($SQL, $con);
+ echo mysql_error($con);
- $TextID_Old = mysql_result( $erg, 0, "TextID" );
- for( $i=0; $i<mysql_num_rows( $erg ); $i++ )
- {
- $TextID_New = mysql_result( $erg, $i, "TextID" );
- if( $TextID_Old != $TextID_New )
- {
- echo "<form action=\"sprache.php\">";
- echo "<tr class=\"content\">\n";
- echo "\t\t<td>$TextID_Old ".
- "<input name=\"TextID\" type=\"hidden\" value=\"$TextID_Old\"> </td>\n";
-
- foreach( $Sprachen as $Name => $Value )
- {
- $Value = html_entity_decode( $Value, ENT_QUOTES);
- echo "\t\t<td><textarea name=\"$Name\" cols=\"22\" rows=\"8\">$Value</textarea></td>\n";
- $Sprachen[ $Name ] = "";
- }
-
- echo "\t\t<td><input type=\"submit\" value=\"Save\"></td>\n";
- echo "</tr>";
- echo "</form>\n";
- $TextID_Old = $TextID_New;
- }
- $Sprachen[ mysql_result( $erg, $i, "Sprache" ) ] = mysql_result( $erg, $i, "Text" );
- } /*FOR*/
- }
-
- //fuer neu eintraege
- echo "<form action=\"sprache.php\">";
- echo "<tr class=\"content\">\n";
- echo "\t\t<td><input name=\"TextID\" type=\"text\" size=\"40\" value=\"new\"> </td>\n";
-
- foreach( $Sprachen as $Name => $Value )
- echo "\t\t<td><textarea name=\"$Name\" cols=\"22\" rows=\"8\">$Name Text</textarea></td>\n";
+ $TextID_Old = mysql_result( $erg, 0, "TextID" );
+ for( $i=0; $i<mysql_num_rows( $erg ); $i++ )
+ {
+ $TextID_New = mysql_result( $erg, $i, "TextID" );
+ if( $TextID_Old != $TextID_New )
+ {
+ echo "<form action=\"sprache.php\">";
+ echo "<tr class=\"content\">\n";
+ echo "\t\t<td>$TextID_Old ".
+ "<input name=\"TextID\" type=\"hidden\" value=\"$TextID_Old\"> </td>\n";
+
+ foreach( $Sprachen as $Name => $Value )
+ {
+ $Value = html_entity_decode( $Value, ENT_QUOTES);
+ echo "\t\t<td><textarea name=\"$Name\" cols=\"22\" rows=\"8\">$Value</textarea></td>\n";
+ $Sprachen[ $Name ] = "";
+ }
+
+ echo "\t\t<td><input type=\"submit\" value=\"Save\"></td>\n";
+ echo "</tr>";
+ echo "</form>\n";
+ $TextID_Old = $TextID_New;
+ }
+ $Sprachen[ mysql_result( $erg, $i, "Sprache" ) ] = mysql_result( $erg, $i, "Text" );
+ } /*FOR*/
+ }
+
+ //fuer neu eintraege
+ echo "<form action=\"sprache.php\">";
+ echo "<tr class=\"content\">\n";
+ echo "\t\t<td><input name=\"TextID\" type=\"text\" size=\"40\" value=\"new\"> </td>\n";
+
+ foreach( $Sprachen as $Name => $Value )
+ echo "\t\t<td><textarea name=\"$Name\" cols=\"22\" rows=\"8\">$Name Text</textarea></td>\n";
- echo "\t\t<td><input type=\"submit\" value=\"Save\"></td>\n";
- echo "</tr>";
- echo "</form>\n";
-
-
- echo "</table>\n";
+ echo "\t\t<td><input type=\"submit\" value=\"Save\"></td>\n";
+ echo "</tr>";
+ echo "</form>\n";
+
+
+ echo "</table>\n";
} /*if( !isset( $TextID ) )*/
else
{
- echo "edit: ". $_GET["TextID"]. "<br><br>";
- foreach ($_GET as $k => $v) {
- if( $k != "TextID" )
- {
- $sql_test = "SELECT * FROM `Sprache` ".
- "WHERE `TextID`='". $_GET["TextID"]. "' AND `Sprache`='$k'";
- $erg_test = mysql_query($sql_test, $con);
+ echo "edit: ". $_GET["TextID"]. "<br /><br />";
+ foreach ($_GET as $k => $v) {
+ if( $k != "TextID" )
+ {
+ $sql_test = "SELECT * FROM `Sprache` ".
+ "WHERE `TextID`='". $_GET["TextID"]. "' AND `Sprache`='$k'";
+ $erg_test = mysql_query($sql_test, $con);
- if( mysql_num_rows($erg_test)==0 )
- {
- $sql_save = "INSERT INTO `Sprache` (`TextID`, `Sprache`, `Text`) ".
- "VALUES ('". $_GET["TextID"]. "', '$k', '$v')";
- echo $sql_save."<br>";
- $Erg = mysql_query($sql_save, $con);
- if ($Erg == 1)
- echo "\t $k Save: OK<br>\n";
- else
- echo "\t $k Save: KO<br>\n";
- }
- else if( mysql_result($erg_test, 0, "Text")!=$v )
- {
- $sql_save = "UPDATE `Sprache` SET `Text`='$v' ".
- "WHERE `TextID`='". $_GET["TextID"]. "' AND `Sprache`='$k' ";
- echo $sql_save."<br>";
- $Erg = mysql_query($sql_save, $con);
- if ($Erg == 1)
- echo "\t $k Update: OK<br>\n";
- else
- echo "\t $k Update: KO<br>\n";
- }
- else
- echo "\t $k no changes<br>\n";
- }
- }
-
+ if( mysql_num_rows($erg_test)==0 )
+ {
+ $sql_save = "INSERT INTO `Sprache` (`TextID`, `Sprache`, `Text`) ".
+ "VALUES ('". $_GET["TextID"]. "', '$k', '$v')";
+ echo $sql_save."<br />";
+ $Erg = mysql_query($sql_save, $con);
+ if ($Erg == 1)
+ echo "\t $k Save: OK<br />\n";
+ else
+ echo "\t $k Save: KO<br />\n";
+ }
+ else if( mysql_result($erg_test, 0, "Text")!=$v )
+ {
+ $sql_save = "UPDATE `Sprache` SET `Text`='$v' ".
+ "WHERE `TextID`='". $_GET["TextID"]. "' AND `Sprache`='$k' ";
+ echo $sql_save."<br />";
+ $Erg = mysql_query($sql_save, $con);
+ if ($Erg == 1)
+ echo "\t $k Update: OK<br />\n";
+ else
+ echo "\t $k Update: KO<br />\n";
+ }
+ else
+ echo "\t $k no changes<br />\n";
+ }
+ }
+
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/tshirt.php b/www-ssl/admin/tshirt.php
index df33494d..6fc3551e 100755..100644
--- a/www-ssl/admin/tshirt.php
+++ b/www-ssl/admin/tshirt.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "T-Shirt-Ausgabe";
$header = "T-Shirt-Ausgabe f&uuml;r aktiven Engel";
@@ -8,22 +8,22 @@ include ("../../../camp2011/includes/funktion_db_list.php");
If (IsSet($_GET["aktiv"])) {
- $SQL="UPDATE `User` SET `Tshirt`='1' WHERE `UID`='". $_GET["aktiv"]. "' limit 1";
- $Erg = mysql_query($SQL, $con);
+ $SQL="UPDATE `User` SET `Tshirt`='1' WHERE `UID`='". $_GET["aktiv"]. "' limit 1";
+ $Erg = mysql_query($SQL, $con);
if ($Erg == 1) {
} else {
- echo "Fehler beim speichern bei Engel ". UID2Nick($_GET["aktive"]). "<br>";
+ echo "Fehler beim speichern bei Engel ". UID2Nick($_GET["aktive"]). "<br />";
}
}
?>
-&Uuml;ber die Suchen-Funktion des Browsers kann diese Liste schnell nach einem Nick abgesucht werden.<br>
-Hinter diesem erscheint ein Link, &uuml;ber den man eintragen kann, dass der Engel sein T-Shirt erhalten hat.<br><br>
+&Uuml;ber die Suchen-Funktion des Browsers kann diese Liste schnell nach einem Nick abgesucht werden.<br />
+Hinter diesem erscheint ein Link, &uuml;ber den man eintragen kann, dass der Engel sein T-Shirt erhalten hat.<br /><br />
Liste aller aktiven Engel:
-<?PHP
+<?php
$SQL = "SELECT * FROM `User` WHERE (`Aktiv`='1') ORDER BY `Nick` ASC";
$Erg = mysql_query($SQL, $con);
@@ -31,12 +31,12 @@ $rowcount = mysql_num_rows($Erg);
?>
<table width="100%" class="border" cellpadding="2" cellspacing="1">
<tr class="contenttopic">
- <td>Nick</td>
- <td>Aktiv?</td>
- <td>Gr&ouml;sse</td>
- <td>T-Shirt ausgeben:</td>
- </td>
-<?PHP
+ <td>Nick</td>
+ <td>Aktiv?</td>
+ <td>Gr&ouml;sse</td>
+ <td>T-Shirt ausgeben:</td>
+ </td>
+<?php
for ($i=0; $i<$rowcount; $i++){
echo "\t<tr class=\"content\">\n";
$eUID=mysql_result($Erg, $i, "UID");
@@ -45,9 +45,9 @@ for ($i=0; $i<$rowcount; $i++){
echo "\t\t<td>".mysql_result($Erg, $i, "Size")."</td>\n";
if (mysql_result($Erg, $i, "Tshirt") =="1") {
- echo "\t\t<td>bereits erhalten</td>";
+ echo "\t\t<td>bereits erhalten</td>";
} else {
- echo "\t\t<td><a href=\"./tshirt.php?aktiv=$eUID\">XXXXXXXX</a></td>";
+ echo "\t\t<td><a href=\"./tshirt.php?aktiv=$eUID\">XXXXXXXX</a></td>";
}
echo "\t</tr>\n";
}
diff --git a/www-ssl/admin/user.php b/www-ssl/admin/user.php
index b86c2382..7d7c3a62 100755..100644
--- a/www-ssl/admin/user.php
+++ b/www-ssl/admin/user.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Editieren der Engelliste";
@@ -7,131 +7,131 @@ include ("../../../camp2011/includes/funktion_db_list.php");
if (!IsSet($_GET["enterUID"]))
{
- // Userliste, keine UID uebergeben...
-
- echo "<a href=\"../makeuser.php\">Neuen Engel eintragen</a><br><br>\n";
-
- if( !isset($_GET["OrderBy"]) ) $_GET["OrderBy"] = "Nick";
- $SQL = "SELECT User.*, UserGroups.Name AS 'Group' FROM `User` ".
- "LEFT JOIN `UserCVS` ON User.UID = UserCVS.UID ".
- "LEFT JOIN `UserGroups` ON UserGroups.UID = UserCVS.GroupID ".
- "ORDER BY `". $_GET["OrderBy"]. "` ASC";
- $Erg = mysql_query($SQL, $con);
- echo mysql_error($con);
-
- // anzahl zeilen
- $Zeilen = mysql_num_rows($Erg);
-
- echo "Anzahl Engel: $Zeilen<br><br>\n";
-
- ?><table width="100%" class="border" cellpadding="2" cellspacing="1">
- <tr class="contenttopic">
- <td>
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Nick">Nick</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=CreateDate">CreateDate</a>
- </td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Name">Name</a></td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Vorname">Vorname</a></td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Alter">Alter</a></td>
- <td>
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=email">@</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=DECT">DECT</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Hometown">Hometown</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=lastLogIn">lastLogIn</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Art">Type</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=ICQ">ICQ</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=jabber">jabber</a> |
- <a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Group">Group</a>
- </td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Size">Gr&ouml;&szlig;e</a></td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Gekommen">G</a></td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Aktiv">A</a></td>
- <td><a href="<?PHP echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Tshirt">T</a></td>
- <td>&Auml;nd.</td>
- <td>Secure</td>
- </tr>
-
-
- <?PHP
- $Gekommen = 0;
- $Active = 0;
- $Tshirt = 0;
-
- for ($n = 0 ; $n < $Zeilen ; $n++) {
- echo "<tr class=\"content\">\n";
- echo "\t<td>".mysql_result($Erg, $n, "Nick"). "<br>(Create: ". mysql_result($Erg, $n, "CreateDate"). ")</td>\n";
- echo "\t<td>".mysql_result($Erg, $n, "Name")."</td>\n";
- echo "\t<td>".mysql_result($Erg, $n, "Vorname")."</td>\n";
- echo "\t<td>".mysql_result($Erg, $n, "Alter")."</td>\n";
- echo "\t<td>";
- if( strlen( mysql_result($Erg, $n, "Telefon"))>0)
- echo "\n\t\tTel: ". mysql_result($Erg, $n, "Telefon"). "<br>";
- if( strlen( mysql_result($Erg, $n, "Handy"))>0)
- echo "\n\t\tHandy: ". mysql_result($Erg, $n, "Handy"). "<br>";
- if( strlen( mysql_result($Erg, $n, "DECT"))>0)
- echo "\n\t\tDECT: <a href=\"./dect.php?custum=". mysql_result($Erg, $n, "DECT"). "\">".
- mysql_result($Erg, $n, "DECT"). "</a><br>";
- if( strlen( mysql_result($Erg, $n, "email"))>0)
- echo "\n\t\temail: <a href=\"mailto:".mysql_result($Erg, $n, "email")."\">".
- mysql_result($Erg, $n, "email")."</a><br>";
- if( strlen( mysql_result($Erg, $n, "Hometown"))>0)
- echo "\n\t\tHometown: ". mysql_result($Erg, $n, "Hometown"). "<br>";
- if( strlen( mysql_result($Erg, $n, "lastLogIn"))>0)
- echo "\n\t\tlastLogIn: ". mysql_result($Erg, $n, "lastLogIn"). "<br>";
- if( strlen( mysql_result($Erg, $n, "Art"))>0)
- echo "\n\t\tType: ". mysql_result($Erg, $n, "Art"). "<br>";
- if( strlen( mysql_result($Erg, $n, "ICQ"))>0)
- echo "\n\t\tICQ: ". mysql_result($Erg, $n, "ICQ"). "<br>";
- if( strlen( mysql_result($Erg, $n, "jabber"))>0)
- echo "\n\t\tjabber: ". mysql_result($Erg, $n, "jabber"). "<br>";
- echo "\n\t\tGroup: ". mysql_result($Erg, $n, "Group"). "<br>";
- echo "</td>\n";
- echo "\t<td>".mysql_result($Erg, $n, "Size")."</td>\n";
- $Gekommen += mysql_result($Erg, $n, "Gekommen");
- echo "\t<td>".mysql_result($Erg, $n, "Gekommen")."</td>\n";
- $Active += mysql_result($Erg, $n, "Aktiv");
- echo "\t<td>".mysql_result($Erg, $n, "Aktiv")."</td>\n";
- $Tshirt += mysql_result($Erg, $n, "Tshirt");
- echo "\t<td>".mysql_result($Erg, $n, "Tshirt")."</td>\n";
- echo "\t<td>". funktion_isLinkAllowed_addLink_OrEmpty(
- "admin/userChangeNormal.php?enterUID=".
- mysql_result($Erg, $n, "UID")."&Type=Normal",
- "&Auml;nd.").
- "</td>\n";
- echo "\t<td>". funktion_isLinkAllowed_addLink_OrEmpty(
- "admin/userChangeSecure.php?enterUID=".
- mysql_result($Erg, $n, "UID")."&Type=Secure",
- "Secure").
- "</td>\n";
- echo "</tr>\n";
- }
- echo "<tr>".
- "<td></td><td></td><td></td><td></td><td></td><td></td>".
- "<td>$Gekommen</td><td>$Active</td><td>$Tshirt</td><td></td></tr>\n";
- echo "\t</table>\n";
- // Ende Userliste
-
- echo "<h1>Statistics</h1>";
- funktion_db_element_list_2row( "Hometown",
- "SELECT COUNT(`Hometown`), `Hometown` FROM `User` GROUP BY `Hometown`");
-
- echo "<br>\n";
-
- funktion_db_element_list_2row( "Engeltypen",
+ // Userliste, keine UID uebergeben...
+
+ echo "<a href=\"../makeuser.php\">Neuen Engel eintragen</a><br /><br />\n";
+
+ if( !isset($_GET["OrderBy"]) ) $_GET["OrderBy"] = "Nick";
+ $SQL = "SELECT User.*, UserGroups.Name AS 'Group' FROM `User` ".
+ "LEFT JOIN `UserCVS` ON User.UID = UserCVS.UID ".
+ "LEFT JOIN `UserGroups` ON UserGroups.UID = UserCVS.GroupID ".
+ "ORDER BY `". $_GET["OrderBy"]. "` ASC";
+ $Erg = mysql_query($SQL, $con);
+ echo mysql_error($con);
+
+ // anzahl zeilen
+ $Zeilen = mysql_num_rows($Erg);
+
+ echo "Anzahl Engel: $Zeilen<br /><br />\n";
+
+ ?><table width="100%" class="border" cellpadding="2" cellspacing="1">
+ <tr class="contenttopic">
+ <td>
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Nick">Nick</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=CreateDate">CreateDate</a>
+ </td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Name">Name</a></td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Vorname">Vorname</a></td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Alter">Alter</a></td>
+ <td>
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=email">@</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=DECT">DECT</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Hometown">Hometown</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=lastLogIn">lastLogIn</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Art">Type</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=ICQ">ICQ</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=jabber">jabber</a> |
+ <a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Group">Group</a>
+ </td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Size">Gr&ouml;&szlig;e</a></td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Gekommen">G</a></td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Aktiv">A</a></td>
+ <td><a href="<?php echo $_SERVER["PHP_SELF"]; ?>?OrderBy=Tshirt">T</a></td>
+ <td>&Auml;nd.</td>
+ <td>Secure</td>
+ </tr>
+
+
+ <?php
+ $Gekommen = 0;
+ $Active = 0;
+ $Tshirt = 0;
+
+ for ($n = 0 ; $n < $Zeilen ; $n++) {
+ echo "<tr class=\"content\">\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Nick"). "<br />(Create: ". mysql_result($Erg, $n, "CreateDate"). ")</td>\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Name")."</td>\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Vorname")."</td>\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Alter")."</td>\n";
+ echo "\t<td>";
+ if( strlen( mysql_result($Erg, $n, "Telefon"))>0)
+ echo "\n\t\tTel: ". mysql_result($Erg, $n, "Telefon"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "Handy"))>0)
+ echo "\n\t\tHandy: ". mysql_result($Erg, $n, "Handy"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "DECT"))>0)
+ echo "\n\t\tDECT: <a href=\"./dect.php?custum=". mysql_result($Erg, $n, "DECT"). "\">".
+ mysql_result($Erg, $n, "DECT"). "</a><br />";
+ if( strlen( mysql_result($Erg, $n, "email"))>0)
+ echo "\n\t\temail: <a href=\"mailto:".mysql_result($Erg, $n, "email")."\">".
+ mysql_result($Erg, $n, "email")."</a><br />";
+ if( strlen( mysql_result($Erg, $n, "Hometown"))>0)
+ echo "\n\t\tHometown: ". mysql_result($Erg, $n, "Hometown"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "lastLogIn"))>0)
+ echo "\n\t\tlastLogIn: ". mysql_result($Erg, $n, "lastLogIn"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "Art"))>0)
+ echo "\n\t\tType: ". mysql_result($Erg, $n, "Art"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "ICQ"))>0)
+ echo "\n\t\tICQ: ". mysql_result($Erg, $n, "ICQ"). "<br />";
+ if( strlen( mysql_result($Erg, $n, "jabber"))>0)
+ echo "\n\t\tjabber: ". mysql_result($Erg, $n, "jabber"). "<br />";
+ echo "\n\t\tGroup: ". mysql_result($Erg, $n, "Group"). "<br />";
+ echo "</td>\n";
+ echo "\t<td>".mysql_result($Erg, $n, "Size")."</td>\n";
+ $Gekommen += mysql_result($Erg, $n, "Gekommen");
+ echo "\t<td>".mysql_result($Erg, $n, "Gekommen")."</td>\n";
+ $Active += mysql_result($Erg, $n, "Aktiv");
+ echo "\t<td>".mysql_result($Erg, $n, "Aktiv")."</td>\n";
+ $Tshirt += mysql_result($Erg, $n, "Tshirt");
+ echo "\t<td>".mysql_result($Erg, $n, "Tshirt")."</td>\n";
+ echo "\t<td>". funktion_isLinkAllowed_addLink_OrEmpty(
+ "admin/userChangeNormal.php?enterUID=".
+ mysql_result($Erg, $n, "UID")."&Type=Normal",
+ "&Auml;nd.").
+ "</td>\n";
+ echo "\t<td>". funktion_isLinkAllowed_addLink_OrEmpty(
+ "admin/userChangeSecure.php?enterUID=".
+ mysql_result($Erg, $n, "UID")."&Type=Secure",
+ "Secure").
+ "</td>\n";
+ echo "</tr>\n";
+ }
+ echo "<tr>".
+ "<td></td><td></td><td></td><td></td><td></td><td></td>".
+ "<td>$Gekommen</td><td>$Active</td><td>$Tshirt</td><td></td></tr>\n";
+ echo "\t</table>\n";
+ // Ende Userliste
+
+ echo "<h1>Statistics</h1>";
+ funktion_db_element_list_2row( "Hometown",
+ "SELECT COUNT(`Hometown`), `Hometown` FROM `User` GROUP BY `Hometown`");
+
+ echo "<br />\n";
+
+ funktion_db_element_list_2row( "Engeltypen",
"SELECT COUNT(`Art`), `Art` FROM `User` GROUP BY `Art`");
- echo "<br>\n";
+ echo "<br />\n";
- funktion_db_element_list_2row( "Used Groups",
- "SELECT UserGroups.Name AS 'GroupName', COUNT(UserGroups.Name) AS Count FROM `UserCVS` ".
- "LEFT JOIN `UserGroups` ON UserGroups.UID = UserCVS.GroupID ".
- "WHERE (UserCVS.GroupID!='NULL') ".
- "GROUP BY `GroupName` ".
- "");
+ funktion_db_element_list_2row( "Used Groups",
+ "SELECT UserGroups.Name AS 'GroupName', COUNT(UserGroups.Name) AS Count FROM `UserCVS` ".
+ "LEFT JOIN `UserGroups` ON UserGroups.UID = UserCVS.GroupID ".
+ "WHERE (UserCVS.GroupID!='NULL') ".
+ "GROUP BY `GroupName` ".
+ "");
}
else
{
- echo "error";
+ echo "error";
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/userArrived.php b/www-ssl/admin/userArrived.php
index da68a5da..a8fdb71e 100755..100644
--- a/www-ssl/admin/userArrived.php
+++ b/www-ssl/admin/userArrived.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Engel Arrived";
$header = "Engel was arrived";
@@ -8,17 +8,17 @@ include ("../../../camp2011/includes/funktion_db_list.php");
If (IsSet($_GET["arrived"])) {
- $SQL="UPDATE `User` SET `Gekommen`='1' WHERE `UID`='". $_GET["arrived"]. "' limit 1";
- $Erg = db_query($SQL, "Set User as Gekommen");
+ $SQL="UPDATE `User` SET `Gekommen`='1' WHERE `UID`='". $_GET["arrived"]. "' limit 1";
+ $Erg = db_query($SQL, "Set User as Gekommen");
if ($Erg == 1) {
- echo "<h2>". Get_Text("pri_userArrived_WriteOK"). " \"". UID2Nick($_GET["arrived"]). "\"</h2>";
+ echo "<h2>". Get_Text("pri_userArrived_WriteOK"). " \"". UID2Nick($_GET["arrived"]). "\"</h2>";
} else {
- echo "<h1>". Get_Text("pri_userArrived_WriteError"). " \"". UID2Nick($_GET["arrived"]). "\"</h1>";
+ echo "<h1>". Get_Text("pri_userArrived_WriteError"). " \"". UID2Nick($_GET["arrived"]). "\"</h1>";
}
}
-echo Get_Text("pri_userArrived_Text1"). "<br>";
-echo Get_Text("pri_userArrived_Text2"). "<br><br>";
+echo Get_Text("pri_userArrived_Text1"). "<br />";
+echo Get_Text("pri_userArrived_Text2"). "<br /><br />";
echo Get_Text("pri_userArrived_TableToppic");
$SQL = "SELECT * FROM `User` ORDER BY `Nick` ASC";
@@ -34,18 +34,18 @@ echo "\t\t<td>". Get_Text("pri_userArrived_TableTD_ArrivedSet"). "</td>\n";
echo "\t</td>\n";
for ($i=0; $i<$rowcount; $i++){
- echo "\t<tr class=\"content\">\n";
- $eUID=mysql_result($Erg, $i, "UID");
- echo "\t\t<td>".UID2Nick($eUID)."</td>\n";
- echo "\t\t<td>".mysql_result($Erg, $i, "Gekommen")."</td>\n";
-
- if (mysql_result($Erg, $i, "Gekommen") =="1")
- {
- echo "\t\t<td>". Get_Text("pri_userArrived_TableEntry_Arrived"). "</td>";
- } else {
- echo "\t\t<td><a href=\"./userArrived.php?arrived=$eUID\">". Get_Text("pri_userArrived_TableEntry_Set"). "</a></td>";
- }
- echo "\t</tr>\n";
+ echo "\t<tr class=\"content\">\n";
+ $eUID=mysql_result($Erg, $i, "UID");
+ echo "\t\t<td>".UID2Nick($eUID)."</td>\n";
+ echo "\t\t<td>".mysql_result($Erg, $i, "Gekommen")."</td>\n";
+
+ if (mysql_result($Erg, $i, "Gekommen") =="1")
+ {
+ echo "\t\t<td>". Get_Text("pri_userArrived_TableEntry_Arrived"). "</td>";
+ } else {
+ echo "\t\t<td><a href=\"./userArrived.php?arrived=$eUID\">". Get_Text("pri_userArrived_TableEntry_Set"). "</a></td>";
+ }
+ echo "\t</tr>\n";
}
echo "</table>";
diff --git a/www-ssl/admin/userChangeNormal.php b/www-ssl/admin/userChangeNormal.php
index 51c49944..6785a030 100755..100644
--- a/www-ssl/admin/userChangeNormal.php
+++ b/www-ssl/admin/userChangeNormal.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Editieren der Engelliste";
@@ -7,128 +7,128 @@ include ("../../../camp2011/includes/funktion_db_list.php");
if (IsSet($_GET["enterUID"]))
{
- // UserID wurde mit uebergeben --> Aendern...
+ // UserID wurde mit uebergeben --> Aendern...
- echo "Hallo,<br>".
- "hier kannst du den Eintrag &auml;ndern. Unter dem Punkt 'Gekommen' ".
- "wird der Engel als anwesend markiert, ein Ja bei Aktiv bedeutet, ".
- "dass der Engel aktiv war und damit ein Anspruch auf ein T-Shirt hat. ".
- "Wenn T-Shirt ein 'Ja' enth&auml;lt, bedeutet dies, dass der Engel ".
- "bereits sein T-Shirt erhalten hat.<br><br>\n";
+ echo "Hallo,<br />".
+ "hier kannst du den Eintrag &auml;ndern. Unter dem Punkt 'Gekommen' ".
+ "wird der Engel als anwesend markiert, ein Ja bei Aktiv bedeutet, ".
+ "dass der Engel aktiv war und damit ein Anspruch auf ein T-Shirt hat. ".
+ "Wenn T-Shirt ein 'Ja' enth&auml;lt, bedeutet dies, dass der Engel ".
+ "bereits sein T-Shirt erhalten hat.<br /><br />\n";
- echo "<form action=\"./userSaveNormal.php?action=change\" method=\"POST\">\n";
- echo "<table border=\"0\">\n";
- echo "<input type=\"hidden\" name=\"Type\" value=\"Normal\">\n";
+ echo "<form action=\"./userSaveNormal.php?action=change\" method=\"POST\">\n";
+ echo "<table border=\"0\">\n";
+ echo "<input type=\"hidden\" name=\"Type\" value=\"Normal\">\n";
- $SQL = "SELECT * FROM `User` WHERE `UID`='". $_GET["enterUID"]. "'";
- $Erg = mysql_query($SQL, $con);
-
- if (mysql_num_rows($Erg) != 1)
- echo "<tr><td>Sorry, der Engel (UID=". $_GET["enterUID"].
- ") wurde in der Liste nicht gefunden.</td></tr>";
- else
- {
- echo "<tr><td>\n";
- echo "<table>\n";
- echo " <tr><td>Nick</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eNick\" value=\"".
- mysql_result($Erg, 0, "Nick")."\"></td></tr>\n";
- echo " <tr><td>lastLogIn</td><td>".
- "<input type=\"text\" size=\"20\" name=\"elastLogIn\" value=\"".
- mysql_result($Erg, 0, "lastLogIn"). "\" disabled></td></tr>\n";
- echo " <tr><td>Name</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eName\" value=\"".
- mysql_result($Erg, 0, "Name")."\"></td></tr>\n";
- echo " <tr><td>Vorname</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eVorname\" value=\"".
- mysql_result($Erg, 0, "Vorname")."\"></td></tr>\n";
- echo " <tr><td>Alter</td><td>".
- "<input type=\"text\" size=\"5\" name=\"eAlter\" value=\"".
- mysql_result($Erg, 0, "Alter")."\"></td></tr>\n";
- echo " <tr><td>Telefon</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eTelefon\" value=\"".
- mysql_result($Erg, 0, "Telefon")."\"></td></tr>\n";
- echo " <tr><td>Handy</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eHandy\" value=\"".
- mysql_result($Erg, 0, "Handy")."\"></td></tr>\n";
- echo " <tr><td>DECT</td><td>".
- "<input type=\"text\" size=\"4\" name=\"eDECT\" value=\"".
- mysql_result($Erg, 0, "DECT")."\"></td></tr>\n";
- echo " <tr><td>email</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eemail\" value=\"".
- mysql_result($Erg, 0, "email")."\"></td></tr>\n";
- echo " <tr><td>ICQ</td><td>".
- "<input type=\"text\" size=\"40\" name=\"eICQ\" value=\"".
- mysql_result($Erg, 0, "ICQ")."\"></td></tr>\n";
- echo " <tr><td>jabber</td><td>".
- "<input type=\"text\" size=\"40\" name=\"ejabber\" value=\"".
- mysql_result($Erg, 0, "jabber")."\"></td></tr>\n";
- echo " <tr><td>Size</td><td>".
- "<input type=\"text\" size=\"5\" name=\"eSize\" value=\"".
- mysql_result($Erg, 0, "Size")."\"></td></tr>\n";
- echo " <tr><td>Passwort</td><td>".
- "<a href=\"./userSaveNormal.php?action=newpw&eUID="
- .mysql_result($Erg, 0, "UID")."\">neues Kennwort setzen</a></td></tr>\n";
+ $SQL = "SELECT * FROM `User` WHERE `UID`='". $_GET["enterUID"]. "'";
+ $Erg = mysql_query($SQL, $con);
+
+ if (mysql_num_rows($Erg) != 1)
+ echo "<tr><td>Sorry, der Engel (UID=". $_GET["enterUID"].
+ ") wurde in der Liste nicht gefunden.</td></tr>";
+ else
+ {
+ echo "<tr><td>\n";
+ echo "<table>\n";
+ echo " <tr><td>Nick</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eNick\" value=\"".
+ mysql_result($Erg, 0, "Nick")."\"></td></tr>\n";
+ echo " <tr><td>lastLogIn</td><td>".
+ "<input type=\"text\" size=\"20\" name=\"elastLogIn\" value=\"".
+ mysql_result($Erg, 0, "lastLogIn"). "\" disabled></td></tr>\n";
+ echo " <tr><td>Name</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eName\" value=\"".
+ mysql_result($Erg, 0, "Name")."\"></td></tr>\n";
+ echo " <tr><td>Vorname</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eVorname\" value=\"".
+ mysql_result($Erg, 0, "Vorname")."\"></td></tr>\n";
+ echo " <tr><td>Alter</td><td>".
+ "<input type=\"text\" size=\"5\" name=\"eAlter\" value=\"".
+ mysql_result($Erg, 0, "Alter")."\"></td></tr>\n";
+ echo " <tr><td>Telefon</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eTelefon\" value=\"".
+ mysql_result($Erg, 0, "Telefon")."\"></td></tr>\n";
+ echo " <tr><td>Handy</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eHandy\" value=\"".
+ mysql_result($Erg, 0, "Handy")."\"></td></tr>\n";
+ echo " <tr><td>DECT</td><td>".
+ "<input type=\"text\" size=\"4\" name=\"eDECT\" value=\"".
+ mysql_result($Erg, 0, "DECT")."\"></td></tr>\n";
+ echo " <tr><td>email</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eemail\" value=\"".
+ mysql_result($Erg, 0, "email")."\"></td></tr>\n";
+ echo " <tr><td>ICQ</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"eICQ\" value=\"".
+ mysql_result($Erg, 0, "ICQ")."\"></td></tr>\n";
+ echo " <tr><td>jabber</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"ejabber\" value=\"".
+ mysql_result($Erg, 0, "jabber")."\"></td></tr>\n";
+ echo " <tr><td>Size</td><td>".
+ "<input type=\"text\" size=\"5\" name=\"eSize\" value=\"".
+ mysql_result($Erg, 0, "Size")."\"></td></tr>\n";
+ echo " <tr><td>Passwort</td><td>".
+ "<a href=\"./userSaveNormal.php?action=newpw&eUID="
+ .mysql_result($Erg, 0, "UID")."\">neues Kennwort setzen</a></td></tr>\n";
- // Gekommen?
- echo " <tr><td>Gekommen</td><td>\n";
- echo " <input type=\"radio\" name=\"eGekommen\" value=\"0\"";
- if (mysql_result($Erg, 0, "Gekommen")=='0')
- echo " checked";
- echo ">No \n";
- echo " <input type=\"radio\" name=\"eGekommen\" value=\"1\"";
- if (mysql_result($Erg, 0, "Gekommen")=='1')
- echo " checked";
- echo ">Yes \n";
- echo "</td></tr>\n";
+ // Gekommen?
+ echo " <tr><td>Gekommen</td><td>\n";
+ echo " <input type=\"radio\" name=\"eGekommen\" value=\"0\"";
+ if (mysql_result($Erg, 0, "Gekommen")=='0')
+ echo " checked";
+ echo ">No \n";
+ echo " <input type=\"radio\" name=\"eGekommen\" value=\"1\"";
+ if (mysql_result($Erg, 0, "Gekommen")=='1')
+ echo " checked";
+ echo ">Yes \n";
+ echo "</td></tr>\n";
- // Aktiv?
- echo " <tr><td>Aktiv</td><td>\n";
- echo " <input type=\"radio\" name=\"eAktiv\" value=\"0\"";
- if (mysql_result($Erg, 0, "Aktiv")=='0')
- echo " checked";
- echo ">No \n";
- echo " <input type=\"radio\" name=\"eAktiv\" value=\"1\"";
- if (mysql_result($Erg, 0, "Aktiv")=='1')
- echo " checked";
- echo ">Yes \n";
- echo "</td></tr>\n";
+ // Aktiv?
+ echo " <tr><td>Aktiv</td><td>\n";
+ echo " <input type=\"radio\" name=\"eAktiv\" value=\"0\"";
+ if (mysql_result($Erg, 0, "Aktiv")=='0')
+ echo " checked";
+ echo ">No \n";
+ echo " <input type=\"radio\" name=\"eAktiv\" value=\"1\"";
+ if (mysql_result($Erg, 0, "Aktiv")=='1')
+ echo " checked";
+ echo ">Yes \n";
+ echo "</td></tr>\n";
- // T-Shirt bekommen?
- echo " <tr><td>T-Shirt</td><td>\n";
- echo " <input type=\"radio\" name=\"eTshirt\" value=\"0\"";
- if (mysql_result($Erg, 0, "Tshirt")=='0')
- echo " checked";
- echo ">No \n";
- echo " <input type=\"radio\" name=\"eTshirt\" value=\"1\"";
- if (mysql_result($Erg, 0, "Tshirt")=='1')
- echo " checked";
- echo ">Yes \n";
- echo "</td></tr>\n";
+ // T-Shirt bekommen?
+ echo " <tr><td>T-Shirt</td><td>\n";
+ echo " <input type=\"radio\" name=\"eTshirt\" value=\"0\"";
+ if (mysql_result($Erg, 0, "Tshirt")=='0')
+ echo " checked";
+ echo ">No \n";
+ echo " <input type=\"radio\" name=\"eTshirt\" value=\"1\"";
+ if (mysql_result($Erg, 0, "Tshirt")=='1')
+ echo " checked";
+ echo ">Yes \n";
+ echo "</td></tr>\n";
- echo " <tr><td>Hometown</td><td>".
- "<input type=\"text\" size=\"40\" name=\"Hometown\" value=\"".
- mysql_result($Erg, 0, "Hometown")."\"></td></tr>\n";
-
- echo "</table>\n</td><td valign=\"top\">". displayavatar($_GET["enterUID"], FALSE). "</td></tr>";
- }
+ echo " <tr><td>Hometown</td><td>".
+ "<input type=\"text\" size=\"40\" name=\"Hometown\" value=\"".
+ mysql_result($Erg, 0, "Hometown")."\"></td></tr>\n";
+
+ echo "</table>\n</td><td valign=\"top\">". displayavatar($_GET["enterUID"], FALSE). "</td></tr>";
+ }
- echo "</td></tr>\n";
- echo "</table>\n<br>\n";
- echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
+ echo "</td></tr>\n";
+ echo "</table>\n<br />\n";
+ echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
- echo "<form action=\"./userSaveNormal.php?action=delete\" method=\"POST\">\n";
- echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
- echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
- echo "</form>";
+ echo "<form action=\"./userSaveNormal.php?action=delete\" method=\"POST\">\n";
+ echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
+ echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
+ echo "</form>";
-
- echo "<hr>";
- funktion_db_element_list_2row(
- "Freeloader Shifts",
- "SELECT `Remove_Time`, `Length`, `Comment` FROM `ShiftFreeloader` WHERE UID=". $_GET["enterUID"]);
+
+ echo "<hr>";
+ funktion_db_element_list_2row(
+ "Freeloader Shifts",
+ "SELECT `Remove_Time`, `Length`, `Comment` FROM `ShiftFreeloader` WHERE UID=". $_GET["enterUID"]);
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/userChangeSecure.php b/www-ssl/admin/userChangeSecure.php
index c1799fb8..2eb84b85 100755..100644
--- a/www-ssl/admin/userChangeSecure.php
+++ b/www-ssl/admin/userChangeSecure.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Editieren der Engelliste";
@@ -7,103 +7,103 @@ include ("../../../camp2011/includes/funktion_db_list.php");
if (IsSet($_GET["enterUID"]))
{
- // UserID wurde mit uebergeben --> Aendern...
+ // UserID wurde mit uebergeben --> Aendern...
- echo "Hallo,<br>".
- "hier kannst du den Eintrag &auml;ndern. Unter dem Punkt 'Gekommen' ".
- "wird der Engel als anwesend markiert, ein Ja bei Aktiv bedeutet, ".
- "dass der Engel aktiv war und damit ein Anspruch auf ein T-Shirt hat. ".
- "Wenn T-Shirt ein 'Ja' enth&auml;lt, bedeutet dies, dass der Engel ".
- "bereits sein T-Shirt erhalten hat.<br><br>\n";
+ echo "Hallo,<br />".
+ "hier kannst du den Eintrag &auml;ndern. Unter dem Punkt 'Gekommen' ".
+ "wird der Engel als anwesend markiert, ein Ja bei Aktiv bedeutet, ".
+ "dass der Engel aktiv war und damit ein Anspruch auf ein T-Shirt hat. ".
+ "Wenn T-Shirt ein 'Ja' enth&auml;lt, bedeutet dies, dass der Engel ".
+ "bereits sein T-Shirt erhalten hat.<br /><br />\n";
- $SQL_CVS = "SELECT * FROM `UserCVS` WHERE `UID`='". $_GET["enterUID"]. "'";
- $Erg_CVS = mysql_query($SQL_CVS, $con);
-
- if( mysql_num_rows($Erg_CVS) != 1)
- echo "Sorry, der Engel (UID=". $_GET["enterUID"]. ") wurde in der Liste nicht gefunden.";
- else
- {
- // Rename if is an group
- if( $_GET["enterUID"] < 0 ) {
- $SQLname = "SELECT `Name` FROM `UserGroups` WHERE `UID`='". $_GET["enterUID"]. "'";
- $ErgName = mysql_query($SQLname, $con);
- echo mysql_error($con);
+ $SQL_CVS = "SELECT * FROM `UserCVS` WHERE `UID`='". $_GET["enterUID"]. "'";
+ $Erg_CVS = mysql_query($SQL_CVS, $con);
+
+ if( mysql_num_rows($Erg_CVS) != 1)
+ echo "Sorry, der Engel (UID=". $_GET["enterUID"]. ") wurde in der Liste nicht gefunden.";
+ else
+ {
+ // Rename if is an group
+ if( $_GET["enterUID"] < 0 ) {
+ $SQLname = "SELECT `Name` FROM `UserGroups` WHERE `UID`='". $_GET["enterUID"]. "'";
+ $ErgName = mysql_query($SQLname, $con);
+ echo mysql_error($con);
- echo "<form action=\"./userSaveSecure.php?action=changeGroupName\" method=\"POST\">\n";
- echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
- echo "<input type=\"text\" name=\"GroupName\" value=\"". mysql_result($ErgName, 0, "Name"). "\">\n";
- echo "<input type=\"submit\" value=\"rename\">\n";
- echo "</form>";
- }
+ echo "<form action=\"./userSaveSecure.php?action=changeGroupName\" method=\"POST\">\n";
+ echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
+ echo "<input type=\"text\" name=\"GroupName\" value=\"". mysql_result($ErgName, 0, "Name"). "\">\n";
+ echo "<input type=\"submit\" value=\"rename\">\n";
+ echo "</form>";
+ }
- echo "<form action=\"./userSaveSecure.php?action=change\" method=\"POST\">\n";
- echo "<table border=\"0\">\n";
- echo "<input type=\"hidden\" name=\"Type\" value=\"Secure\">\n";
- echo " <tr><td><br><u>Rights of \"". UID2Nick($_GET["enterUID"]). "\":</u></td></tr>\n";
+ echo "<form action=\"./userSaveSecure.php?action=change\" method=\"POST\">\n";
+ echo "<table border=\"0\">\n";
+ echo "<input type=\"hidden\" name=\"Type\" value=\"Secure\">\n";
+ echo " <tr><td><br /><u>Rights of \"". UID2Nick($_GET["enterUID"]). "\":</u></td></tr>\n";
- $CVS_Data = mysql_fetch_array($Erg_CVS);
- $CVS_Data_i = 1;
- foreach ($CVS_Data as $CVS_Data_Name => $CVS_Data_Value)
- {
- $CVS_Data_i++;
- //nur jeder zweiter sonst wird für jeden text noch die position (Zahl) ausgegeben
- if( $CVS_Data_i%2 && $CVS_Data_Name!="UID")
- {
- if($CVS_Data_Name=="GroupID") {
- if( $_GET["enterUID"] > 0 )
- {
- echo "<tr><td><b>Group</b></td>\n".
- "<td><select name=\"GroupID\">";
+ $CVS_Data = mysql_fetch_array($Erg_CVS);
+ $CVS_Data_i = 1;
+ foreach ($CVS_Data as $CVS_Data_Name => $CVS_Data_Value)
+ {
+ $CVS_Data_i++;
+ //nur jeder zweiter sonst wird für jeden text noch die position (Zahl) ausgegeben
+ if( $CVS_Data_i%2 && $CVS_Data_Name!="UID")
+ {
+ if($CVS_Data_Name=="GroupID") {
+ if( $_GET["enterUID"] > 0 )
+ {
+ echo "<tr><td><b>Group</b></td>\n".
+ "<td><select name=\"GroupID\">";
- $SQL_Group = "SELECT * FROM `UserGroups`";
- $Erg_Group = mysql_query($SQL_Group, $con);
- for ($n = 0 ; $n < mysql_num_rows($Erg_Group) ; $n++)
- {
- $UID = mysql_result($Erg_Group, $n, "UID");
- echo "\t<option value=\"$UID\"";
- if( $CVS_Data_Value == $UID)
- echo " selected";
- echo ">". mysql_result($Erg_Group, $n, "Name"). "</option>\n";
- }
- echo "</select></td></tr>";
- }
- } else {
- echo "<tr><td>$CVS_Data_Name</td>\n<td>";
- echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"Y\" ";
- if( $CVS_Data_Value == "Y" )
- echo " checked";
- echo ">allow \n";
- echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"N\" ";
- if( $CVS_Data_Value == "N" )
- echo " checked";
- echo ">denied \n";
- if( $_GET["enterUID"] > 0 )
- {
- echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"G\" ";
- if( $CVS_Data_Value == "G" )
- echo " checked";
- echo ">group-setting \n";
- echo "</td></tr>";
- }
- }
- } //IF
- } //Foreach
- echo "</td></tr>\n";
-
- // Ende Formular
- echo "</td></tr>\n";
- echo "</table>\n<br>\n";
- echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
+ $SQL_Group = "SELECT * FROM `UserGroups`";
+ $Erg_Group = mysql_query($SQL_Group, $con);
+ for ($n = 0 ; $n < mysql_num_rows($Erg_Group) ; $n++)
+ {
+ $UID = mysql_result($Erg_Group, $n, "UID");
+ echo "\t<option value=\"$UID\"";
+ if( $CVS_Data_Value == $UID)
+ echo " selected";
+ echo ">". mysql_result($Erg_Group, $n, "Name"). "</option>\n";
+ }
+ echo "</select></td></tr>";
+ }
+ } else {
+ echo "<tr><td>$CVS_Data_Name</td>\n<td>";
+ echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"Y\" ";
+ if( $CVS_Data_Value == "Y" )
+ echo " checked";
+ echo ">allow \n";
+ echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"N\" ";
+ if( $CVS_Data_Value == "N" )
+ echo " checked";
+ echo ">denied \n";
+ if( $_GET["enterUID"] > 0 )
+ {
+ echo "<input type=\"radio\" name=\"".($CVS_Data_i-1)."\" value=\"G\" ";
+ if( $CVS_Data_Value == "G" )
+ echo " checked";
+ echo ">group-setting \n";
+ echo "</td></tr>";
+ }
+ }
+ } //IF
+ } //Foreach
+ echo "</td></tr>\n";
+
+ // Ende Formular
+ echo "</td></tr>\n";
+ echo "</table>\n<br />\n";
+ echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
- echo "<br><form action=\"./userSaveSecure.php?action=delete\" method=\"POST\">\n";
- echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
- echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
- echo "</form>";
- }
+ echo "<br /><form action=\"./userSaveSecure.php?action=delete\" method=\"POST\">\n";
+ echo "<input type=\"hidden\" name=\"enterUID\" value=\"". $_GET["enterUID"]. "\">\n";
+ echo "<input type=\"submit\" value=\"l&ouml;schen...\">\n";
+ echo "</form>";
+ }
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/userDefaultSetting.php b/www-ssl/admin/userDefaultSetting.php
index d3564400..d4a230de 100755..100644
--- a/www-ssl/admin/userDefaultSetting.php
+++ b/www-ssl/admin/userDefaultSetting.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "Defalut User Setting";
$header = "Defalut User Setting";
@@ -6,8 +6,8 @@ include ("../../../camp2011/includes/header.php");
include ("../../../camp2011/includes/funktion_db_list.php");
echo "Hallo ".$_SESSION['Nick'].
- ",<br>\nhier hast du die M&ouml;glichkeit, die Defaulteinstellungen f&uuml;r neue User einzustellen:<br><br>\n";
-
+ ",<br />\nhier hast du die M&ouml;glichkeit, die Defaulteinstellungen f&uuml;r neue User einzustellen:<br /><br />\n";
+
echo "<table border=\"0\" class=\"border\">\n";
echo "\t<tr class=\"contenttopic\">\n";
echo "\t\t<th>Page</th>\n\t\t<th>Show</th>\n\t\t<th></th>\n";
@@ -15,55 +15,55 @@ echo "\t</tr>\n";
if( isset( $_GET["Field"]) && isset( $_GET["Default"]) && isset( $_GET["Send"]))
{
- switch( $_GET["Send"])
- {
- case "New":
- $SQL = "ALTER TABLE `UserCVS` ADD `". $_GET["Field"]. "` ".
- "CHAR( 1 ) DEFAULT '". $_GET["Default"]. "' NOT NULL";
- $Erg = db_query( $SQL, "New user default setting");
- if( $Erg == 1)
- echo "<H2>Create ".$_GET["Field"]. " = ". $_GET["Default"]. " succesfull</h2>\n";
- else
- echo "<H2>Create ".$_GET["Field"]. " = ". $_GET["Default"]. " error...</h2>\n".
- "[". mysql_error(). "]<br><br>";
- break;
- case "Del":
- echo "\t<tr class=\"content\">\n";
- echo "\t\t<form action=\"userDefaultSetting.php\">\n";
- echo "\t\t\t<td><input name=\"Field\" type=\"text\" value=\"". $_GET["Field"]. "\" readonly></td>\n";
- echo "\t\t\t<td><input name=\"Default\" type=\"text\" value=\"". $_GET["Default"]. "\" readonly></td>\n";
- echo "\t\t\t<td><input type=\"submit\" name=\"Send\" value=\"Del sure\"></td>\n";
- echo "\t\t</form>\n";
- echo "\t</tr>\n";
- break;
- case "Del sure":
- $SQL = "ALTER TABLE `UserCVS` DROP `". $_GET["Field"]. "` ";
- $Erg = db_query( $SQL, "del user default setting");
- if( $Erg == 1)
- echo "<H2>Delete ".$_GET["Field"]. " succesfull</h2>\n";
- else
- echo "<H2>Delete ".$_GET["Field"]. " error...</h2>\n".
- "[". mysql_error(). "]<br><br>";
- break;
- case "SetForAllUser":
- $SQL = "UPDATE `UserCVS` SET `". $_GET["Field"]. "`='". $_GET["Default"]. "' WHERE UID>0";
- $Erg = db_query( $SQL, "Set new user default setting for all user");
- if( $Erg == 1)
- echo "<H2>UPDATE ".$_GET["Field"]. " = ". $_GET["Default"]. " for all Users succesfull</h2>\n";
- else
- echo "<H2>UPDATE ".$_GET["Field"]. " = ". $_GET["Default"]. " for all Users error...</h2>\n".
- "[". mysql_error(). "]<br><br>";
- case "Save":
- $SQL = "ALTER TABLE `UserCVS` CHANGE `". $_GET["Field"]. "` ".
- "`". $_GET["Field"]. "` CHAR( 1 ) NOT NULL DEFAULT '". $_GET["Default"]. "'";
- $Erg = db_query( $SQL, "Save user default setting");
- if( $Erg == 1)
- echo "<H2>Write ".$_GET["Field"]. " = ". $_GET["Default"]. " succesfull</h2>\n";
- else
- echo "<H2>Write ".$_GET["Field"]. " = ". $_GET["Default"]. " error...</h2>\n".
- "[". mysql_error(). "]<br><br>";
- break;
- } //SWITCH
+ switch( $_GET["Send"])
+ {
+ case "New":
+ $SQL = "ALTER TABLE `UserCVS` ADD `". $_GET["Field"]. "` ".
+ "CHAR( 1 ) DEFAULT '". $_GET["Default"]. "' NOT NULL";
+ $Erg = db_query( $SQL, "New user default setting");
+ if( $Erg == 1)
+ echo "<H2>Create ".$_GET["Field"]. " = ". $_GET["Default"]. " succesfull</h2>\n";
+ else
+ echo "<H2>Create ".$_GET["Field"]. " = ". $_GET["Default"]. " error...</h2>\n".
+ "[". mysql_error(). "]<br /><br />";
+ break;
+ case "Del":
+ echo "\t<tr class=\"content\">\n";
+ echo "\t\t<form action=\"userDefaultSetting.php\">\n";
+ echo "\t\t\t<td><input name=\"Field\" type=\"text\" value=\"". $_GET["Field"]. "\" readonly></td>\n";
+ echo "\t\t\t<td><input name=\"Default\" type=\"text\" value=\"". $_GET["Default"]. "\" readonly></td>\n";
+ echo "\t\t\t<td><input type=\"submit\" name=\"Send\" value=\"Del sure\"></td>\n";
+ echo "\t\t</form>\n";
+ echo "\t</tr>\n";
+ break;
+ case "Del sure":
+ $SQL = "ALTER TABLE `UserCVS` DROP `". $_GET["Field"]. "` ";
+ $Erg = db_query( $SQL, "del user default setting");
+ if( $Erg == 1)
+ echo "<H2>Delete ".$_GET["Field"]. " succesfull</h2>\n";
+ else
+ echo "<H2>Delete ".$_GET["Field"]. " error...</h2>\n".
+ "[". mysql_error(). "]<br /><br />";
+ break;
+ case "SetForAllUser":
+ $SQL = "UPDATE `UserCVS` SET `". $_GET["Field"]. "`='". $_GET["Default"]. "' WHERE UID>0";
+ $Erg = db_query( $SQL, "Set new user default setting for all user");
+ if( $Erg == 1)
+ echo "<H2>UPDATE ".$_GET["Field"]. " = ". $_GET["Default"]. " for all Users succesfull</h2>\n";
+ else
+ echo "<H2>UPDATE ".$_GET["Field"]. " = ". $_GET["Default"]. " for all Users error...</h2>\n".
+ "[". mysql_error(). "]<br /><br />";
+ case "Save":
+ $SQL = "ALTER TABLE `UserCVS` CHANGE `". $_GET["Field"]. "` ".
+ "`". $_GET["Field"]. "` CHAR( 1 ) NOT NULL DEFAULT '". $_GET["Default"]. "'";
+ $Erg = db_query( $SQL, "Save user default setting");
+ if( $Erg == 1)
+ echo "<H2>Write ".$_GET["Field"]. " = ". $_GET["Default"]. " succesfull</h2>\n";
+ else
+ echo "<H2>Write ".$_GET["Field"]. " = ". $_GET["Default"]. " error...</h2>\n".
+ "[". mysql_error(). "]<br /><br />";
+ break;
+ } //SWITCH
} //IF(
@@ -79,11 +79,11 @@ $SQL_Group = "SELECT * FROM `UserGroups`";
$Erg_Group = mysql_query($SQL_Group, $con);
for ($n = 0 ; $n < mysql_num_rows($Erg_Group) ; $n++)
{
- $UID = mysql_result($Erg_Group, $n, "UID");
- echo "\t<option value=\"$UID\"";
- if( mysql_result( $erg, 1, "Default") == $UID)
- echo " selected";
- echo ">". mysql_result($Erg_Group, $n, "Name"). "</option>\n";
+ $UID = mysql_result($Erg_Group, $n, "UID");
+ echo "\t<option value=\"$UID\"";
+ if( mysql_result( $erg, 1, "Default") == $UID)
+ echo " selected";
+ echo ">". mysql_result($Erg_Group, $n, "Name"). "</option>\n";
}
echo "</select></td>\n";
echo "\t\t\t<td><input type=\"submit\" name=\"Send\" value=\"Save\">\n";
@@ -93,35 +93,35 @@ echo "\t</tr>\n";
for( $i=2; $i<mysql_num_rows($erg); $i++)
{
- echo "\t<tr class=\"content\">\n";
- echo "\t\t<form action=\"userDefaultSetting.php\">\n";
- echo "\t\t\t<input name=\"Field\" type=\"hidden\" value=\"". mysql_result( $erg, $i, "Field"). "\">\n";
- echo "\t\t\t<td>". mysql_result( $erg, $i, "Field"). "</td>\n";
- echo "\t\t\t<td>\n";
-
- echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"Y\"";
- if( mysql_result( $erg, $i, "Default") == "Y")
- echo " checked";
- echo ">allow\n";
+ echo "\t<tr class=\"content\">\n";
+ echo "\t\t<form action=\"userDefaultSetting.php\">\n";
+ echo "\t\t\t<input name=\"Field\" type=\"hidden\" value=\"". mysql_result( $erg, $i, "Field"). "\">\n";
+ echo "\t\t\t<td>". mysql_result( $erg, $i, "Field"). "</td>\n";
+ echo "\t\t\t<td>\n";
+
+ echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"Y\"";
+ if( mysql_result( $erg, $i, "Default") == "Y")
+ echo " checked";
+ echo ">allow\n";
- echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"N\"";
- if( mysql_result( $erg, $i, "Default") == "N")
- echo " checked";
- echo ">denied\n";
+ echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"N\"";
+ if( mysql_result( $erg, $i, "Default") == "N")
+ echo " checked";
+ echo ">denied\n";
- echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"G\"";
- if( mysql_result( $erg, $i, "Default") == "G")
- echo " checked";
- echo ">group-setting\n";
+ echo "\t\t\t\t<input type=\"radio\" name=\"Default\" value=\"G\"";
+ if( mysql_result( $erg, $i, "Default") == "G")
+ echo " checked";
+ echo ">group-setting\n";
- echo "\t\t\t</td>\n";
- echo "\t\t\t<td><input type=\"submit\" name=\"Send\" value=\"Save\">\n";
- echo "\t\t\t <input type=\"submit\" name=\"Send\" value=\"Del\">\n";
- echo "\t\t\t <input type=\"submit\" name=\"Send\" value=\"SetForAllUser\"></td>\n";
- echo "\t\t</form>\n";
- echo "\t</tr>\n";
+ echo "\t\t\t</td>\n";
+ echo "\t\t\t<td><input type=\"submit\" name=\"Send\" value=\"Save\">\n";
+ echo "\t\t\t <input type=\"submit\" name=\"Send\" value=\"Del\">\n";
+ echo "\t\t\t <input type=\"submit\" name=\"Send\" value=\"SetForAllUser\"></td>\n";
+ echo "\t\t</form>\n";
+ echo "\t</tr>\n";
}
-
+
echo "\t<tr class=\"content\">\n";
echo "\t\t<form action=\"userDefaultSetting.php\">\n";
echo "\t\t\t<input name=\"New\" type=\"hidden\" value=\"New\">\n";
diff --git a/www-ssl/admin/userSaveNormal.php b/www-ssl/admin/userSaveNormal.php
index 4a7f7126..b1b42f96 100755..100644
--- a/www-ssl/admin/userSaveNormal.php
+++ b/www-ssl/admin/userSaveNormal.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Index";
@@ -9,120 +9,120 @@ include ("../../../camp2011/includes/funktion_db.php");
if (IsSet($_GET["action"]))
{
- SetHeaderGo2Back();
- echo "Gesendeter Befehl: ". $_GET["action"]. "<br>";
+ SetHeaderGo2Back();
+ echo "Gesendeter Befehl: ". $_GET["action"]. "<br />";
- switch ($_GET["action"])
- {
- case "change":
- if (IsSet($_POST["enterUID"]))
- {
- if ($_POST["Type"] == "Normal")
- {
- $SQL = "UPDATE `User` SET ";
- $SQL.= " `Nick` = '". $_POST["eNick"]. "', `Name` = '". $_POST["eName"]. "', ".
- "`Vorname` = '". $_POST["eVorname"]. "', ".
- "`Telefon` = '". $_POST["eTelefon"]. "', ".
- "`Handy` = '". $_POST["eHandy"]. "', ".
- "`DECT` = '". $_POST["eDECT"]. "', ".
- "`email` = '". $_POST["eemail"]. "', ".
- "`ICQ` = '". $_POST["eICQ"]. "', ".
- "`jabber` = '". $_POST["ejabber"]. "', ".
- "`Size` = '". $_POST["eSize"]. "', ".
- "`Gekommen`= '". $_POST["eGekommen"]. "', ".
- "`Aktiv`= '". $_POST["eAktiv"]. "', ".
- "`Tshirt` = '". $_POST["eTshirt"]. "', ".
- "`Hometown` = '". $_POST["Hometown"]. "' ".
- "WHERE `UID` = '". $_POST["enterUID"].
- "' LIMIT 1;";
- echo "User-";
- $Erg = db_query($SQL, "change user details");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- }
- else
- echo "<h1>Fehler: Unbekanter Type (". $_POST["Type"]. ") übergeben\n</h1>\n";
- }
- else
- echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
- break;
+ switch ($_GET["action"])
+ {
+ case "change":
+ if (IsSet($_POST["enterUID"]))
+ {
+ if ($_POST["Type"] == "Normal")
+ {
+ $SQL = "UPDATE `User` SET ";
+ $SQL.= " `Nick` = '". $_POST["eNick"]. "', `Name` = '". $_POST["eName"]. "', ".
+ "`Vorname` = '". $_POST["eVorname"]. "', ".
+ "`Telefon` = '". $_POST["eTelefon"]. "', ".
+ "`Handy` = '". $_POST["eHandy"]. "', ".
+ "`DECT` = '". $_POST["eDECT"]. "', ".
+ "`email` = '". $_POST["eemail"]. "', ".
+ "`ICQ` = '". $_POST["eICQ"]. "', ".
+ "`jabber` = '". $_POST["ejabber"]. "', ".
+ "`Size` = '". $_POST["eSize"]. "', ".
+ "`Gekommen`= '". $_POST["eGekommen"]. "', ".
+ "`Aktiv`= '". $_POST["eAktiv"]. "', ".
+ "`Tshirt` = '". $_POST["eTshirt"]. "', ".
+ "`Hometown` = '". $_POST["Hometown"]. "' ".
+ "WHERE `UID` = '". $_POST["enterUID"].
+ "' LIMIT 1;";
+ echo "User-";
+ $Erg = db_query($SQL, "change user details");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ }
+ else
+ echo "<h1>Fehler: Unbekanter Type (". $_POST["Type"]. ") übergeben\n</h1>\n";
+ }
+ else
+ echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
+ break;
- case "delete":
- if (IsSet($_POST["enterUID"]))
- {
- echo "delate User...";
- $SQL="DELETE FROM `User` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL, "User delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- echo "<br>\ndelate UserCVS...";
- $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL2, "User CVS delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- echo "<br>\ndelate UserEntry...";
- $SQL3="UPDATE `ShiftEntry` SET `UID`='0', `Comment`=NULL ".
- "WHERE `UID`='". $_POST["enterUID"]. "';";
- $Erg = db_query($SQL3, "delate UserEntry");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- }
- break;
+ case "delete":
+ if (IsSet($_POST["enterUID"]))
+ {
+ echo "delate User...";
+ $SQL="DELETE FROM `User` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL, "User delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ echo "<br />\ndelate UserCVS...";
+ $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL2, "User CVS delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ echo "<br />\ndelate UserEntry...";
+ $SQL3="UPDATE `ShiftEntry` SET `UID`='0', `Comment`=NULL ".
+ "WHERE `UID`='". $_POST["enterUID"]. "';";
+ $Erg = db_query($SQL3, "delate UserEntry");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ }
+ break;
- case "newpw":
- echo "Bitte neues Kennwort f&uuml;r <b>";
- // Get Nick
- $USQL = "SELECT * FROM `User` WHERE `UID`='". $_GET["eUID"]. "'";
- $Erg = mysql_query($USQL, $con);
- echo mysql_result($Erg, 0, "Nick");
- echo "</b> eingeben:<br>";
- echo "<form action=\"./userSaveNormal.php?action=newpwsave\" method=\"POST\">\n";
- echo "<input type=\"Password\" name=\"ePasswort\">";
- echo "<input type=\"Password\" name=\"ePasswort2\">";
- echo "<input type=\"hidden\" name=\"eUID\" value=\"". $_GET["eUID"]. "\">";
- echo "<input type=\"submit\" value=\"sichern...\">\n";
- echo "</form>";
- break;
+ case "newpw":
+ echo "Bitte neues Kennwort f&uuml;r <b>";
+ // Get Nick
+ $USQL = "SELECT * FROM `User` WHERE `UID`='". $_GET["eUID"]. "'";
+ $Erg = mysql_query($USQL, $con);
+ echo mysql_result($Erg, 0, "Nick");
+ echo "</b> eingeben:<br />";
+ echo "<form action=\"./userSaveNormal.php?action=newpwsave\" method=\"POST\">\n";
+ echo "<input type=\"Password\" name=\"ePasswort\">";
+ echo "<input type=\"Password\" name=\"ePasswort2\">";
+ echo "<input type=\"hidden\" name=\"eUID\" value=\"". $_GET["eUID"]. "\">";
+ echo "<input type=\"submit\" value=\"sichern...\">\n";
+ echo "</form>";
+ break;
- case "newpwsave":
- if ($_POST["ePasswort"] == $_POST["ePasswort2"])
- { // beide Passwoerter passen...
- $_POST["ePasswort"] = PassCrypt($_POST["ePasswort"]);
- $SQL = "UPDATE `User` SET `Passwort`='". $_POST["ePasswort"]. "' ".
- "WHERE `UID`='". $_POST["eUID"]. "'";
- $Erg = db_query($SQL, "User new passwort");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- }
- else
- echo "Das Passwort wurde nicht &uuml;bereinstimmend eingegeben!";
- break;
- } // end switch
+ case "newpwsave":
+ if ($_POST["ePasswort"] == $_POST["ePasswort2"])
+ { // beide Passwoerter passen...
+ $_POST["ePasswort"] = PassCrypt($_POST["ePasswort"]);
+ $SQL = "UPDATE `User` SET `Passwort`='". $_POST["ePasswort"]. "' ".
+ "WHERE `UID`='". $_POST["eUID"]. "'";
+ $Erg = db_query($SQL, "User new passwort");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ }
+ else
+ echo "Das Passwort wurde nicht &uuml;bereinstimmend eingegeben!";
+ break;
+ } // end switch
// ende - Action ist gesetzt
}
else
{
- // kein Action gesetzt -> abbruch
- echo "Unzul&auml;ssiger Aufruf.<br>Bitte neu editieren...";
+ // kein Action gesetzt -> abbruch
+ echo "Unzul&auml;ssiger Aufruf.<br />Bitte neu editieren...";
}
include ("../../../camp2011/includes/footer.php");
diff --git a/www-ssl/admin/userSaveSecure.php b/www-ssl/admin/userSaveSecure.php
index 277c7127..e9ad6135 100755..100644
--- a/www-ssl/admin/userSaveSecure.php
+++ b/www-ssl/admin/userSaveSecure.php
@@ -1,4 +1,4 @@
-<?PHP
+<?php
$title = "User-Liste";
$header = "Index";
@@ -9,168 +9,168 @@ include ("../../../camp2011/includes/funktion_db.php");
if( !IsSet($_POST["enterUID"]) )
{
- $Right = "N";
+ $Right = "N";
} elseif( $_POST["enterUID"] > 0 ) {
- $Right = $_SESSION['CVS'][ "admin/user.php"];
+ $Right = $_SESSION['CVS'][ "admin/user.php"];
} else {
- $Right = $_SESSION['CVS'][ "admin/group.php"];
+ $Right = $_SESSION['CVS'][ "admin/group.php"];
}
if ( ($Right=="Y") && IsSet($_GET["action"]))
{
- SetHeaderGo2Back();
- echo "Gesendeter Befehl: ". $_GET["action"]. "<br>";
-
- switch ($_GET["action"])
- {
- case "change":
- if (IsSet($_POST["enterUID"]))
- {
- if ($_POST["Type"] == "Secure")
- {
- $SQL2 = "UPDATE `UserCVS` SET ";
- $SQL_CVS = "SELECT * FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "'";
- $Erg_CVS = mysql_query($SQL_CVS, $con);
- $CVS_Data = mysql_fetch_array($Erg_CVS);
- $CVS_Data_i = 1;
- foreach ($CVS_Data as $CVS_Data_Name => $CVS_Data_Value)
- {
- if( ($CVS_Data_i+1)%2 && $CVS_Data_Name!="UID") {
- if( $CVS_Data_Name == "GroupID")
- {
- if( $_POST["enterUID"] > 0 )
- $SQL2.= "`$CVS_Data_Name` = '". $_POST["GroupID"]."', ";
- else
- $SQL2.= "`$CVS_Data_Name` = NULL, ";
- } else {
- $SQL2.= "`$CVS_Data_Name` = '". $_POST[$CVS_Data_i]."', ";
- }
- }
- $CVS_Data_i++;
- }
- $SQL2 = substr( $SQL2, 0, strlen($SQL2)-2 );
- $SQL2.= " WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- echo "<br>Secure-";
- $Erg = db_query($SQL2, "change user CVS");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- }
- else
- echo "<h1>Fehler: Unbekanter Type (". $_POST["Type"]. ") übergeben\n</h1>\n";
- }
- else
- echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
- break;
+ SetHeaderGo2Back();
+ echo "Gesendeter Befehl: ". $_GET["action"]. "<br />";
+
+ switch ($_GET["action"])
+ {
+ case "change":
+ if (IsSet($_POST["enterUID"]))
+ {
+ if ($_POST["Type"] == "Secure")
+ {
+ $SQL2 = "UPDATE `UserCVS` SET ";
+ $SQL_CVS = "SELECT * FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "'";
+ $Erg_CVS = mysql_query($SQL_CVS, $con);
+ $CVS_Data = mysql_fetch_array($Erg_CVS);
+ $CVS_Data_i = 1;
+ foreach ($CVS_Data as $CVS_Data_Name => $CVS_Data_Value)
+ {
+ if( ($CVS_Data_i+1)%2 && $CVS_Data_Name!="UID") {
+ if( $CVS_Data_Name == "GroupID")
+ {
+ if( $_POST["enterUID"] > 0 )
+ $SQL2.= "`$CVS_Data_Name` = '". $_POST["GroupID"]."', ";
+ else
+ $SQL2.= "`$CVS_Data_Name` = NULL, ";
+ } else {
+ $SQL2.= "`$CVS_Data_Name` = '". $_POST[$CVS_Data_i]."', ";
+ }
+ }
+ $CVS_Data_i++;
+ }
+ $SQL2 = substr( $SQL2, 0, strlen($SQL2)-2 );
+ $SQL2.= " WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ echo "<br />Secure-";
+ $Erg = db_query($SQL2, "change user CVS");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ }
+ else
+ echo "<h1>Fehler: Unbekanter Type (". $_POST["Type"]. ") übergeben\n</h1>\n";
+ }
+ else
+ echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
+ break;
- case "changeGroupName":
- if (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]<0) )
- {
- $SQL = "UPDATE `UserGroups` SET `Name`='". $_POST["GroupName"]. "' WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1 ;";
- $Erg = db_query($SQL, "Update Group Name");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- }
- else
- echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
- break;
+ case "changeGroupName":
+ if (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]<0) )
+ {
+ $SQL = "UPDATE `UserGroups` SET `Name`='". $_POST["GroupName"]. "' WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1 ;";
+ $Erg = db_query($SQL, "Update Group Name");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ }
+ else
+ echo "<h1>Fehler: UserID (enterUID) wurde nicht per POST übergeben</h1>\n";
+ break;
- case "delete":
- if (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]>0) )
- {
- echo "delate User...";
- $SQL="DELETE FROM `User` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL, "User delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- echo "<br>\ndelate UserCVS...";
- $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL2, "User CVS delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- echo "<br>\ndelate UserEntry...";
- $SQL3="UPDATE `ShiftEntry` SET `UID`='0', `Comment`=NULL ".
- "WHERE `UID`='". $_POST["enterUID"]. "';";
- $Erg = db_query($SQL3, "delate UserEntry");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
- } elseif (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]<0) ) {
- echo "delate Group...";
- $SQL="DELETE FROM `UserGroups` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL, "Group delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- echo "<br>\ndelate UserCVS...";
- $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
- $Erg = db_query($SQL2, "User CVS delete");
- if ($Erg == 1) {
- echo "&Auml;nderung wurde gesichert...\n";
- } else {
- echo "Fehler beim speichern...\n(". mysql_error($con). ")";
- }
-
- }
- break;
- } // end switch
+ case "delete":
+ if (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]>0) )
+ {
+ echo "delate User...";
+ $SQL="DELETE FROM `User` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL, "User delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ echo "<br />\ndelate UserCVS...";
+ $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL2, "User CVS delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ echo "<br />\ndelate UserEntry...";
+ $SQL3="UPDATE `ShiftEntry` SET `UID`='0', `Comment`=NULL ".
+ "WHERE `UID`='". $_POST["enterUID"]. "';";
+ $Erg = db_query($SQL3, "delate UserEntry");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+ } elseif (IsSet($_POST["enterUID"]) && ($_POST["enterUID"]<0) ) {
+ echo "delate Group...";
+ $SQL="DELETE FROM `UserGroups` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL, "Group delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ echo "<br />\ndelate UserCVS...";
+ $SQL2="DELETE FROM `UserCVS` WHERE `UID`='". $_POST["enterUID"]. "' LIMIT 1;";
+ $Erg = db_query($SQL2, "User CVS delete");
+ if ($Erg == 1) {
+ echo "&Auml;nderung wurde gesichert...\n";
+ } else {
+ echo "Fehler beim speichern...\n(". mysql_error($con). ")";
+ }
+
+ }
+ break;
+ } // end switch
// ende - Action ist gesetzt
} elseif ( IsSet($_GET["new"]) && ($_SESSION['CVS']["admin/group.php"]=="Y") ) {
- echo "Gesendeter Befehl: ". $_GET["new"]. "<br>";
-
- switch ($_GET["new"])
- {
- case "newGroup":
- echo "\tGenerate new Group ID...\n";
- $SQLid="SELECT MIN(`UID`) FROM `UserCVS`;";
- $Erg = mysql_query( $SQLid);
-
- if( mysql_num_rows($Erg) == 1) {
- $NewId = mysql_result( $Erg, 0, 0)-1;
- $SQLnew1 = "INSERT INTO `UserGroups` (`UID`, `Name`) VALUES ('$NewId', '". $_POST["GroupName"]. "' );";
- $SQLnew2 = "INSERT INTO `UserCVS` (`UID`, `GroupID`) VALUES ('$NewId', NULL );";
- echo "\t<br>Generate new UserGroup ...\n";
- $ErgNew1 = db_query($SQLnew1, "create UserGroups Entry");
- if ($ErgNew1 == 1)
- {
- echo "\t<br>Generate new User rights...\n";
- $ErgNew2 = db_query($SQLnew2, "UserCVS Entry");
- if ($ErgNew1 == 1) {
- echo "\t<br>New group was created.\n";
- } else {
- echo "Error on creation\n(". mysql_error($con). ")";
- }
- } else {
- echo "Error on creation\n(". mysql_error($con). ")";
- }
+ echo "Gesendeter Befehl: ". $_GET["new"]. "<br />";
+
+ switch ($_GET["new"])
+ {
+ case "newGroup":
+ echo "\tGenerate new Group ID...\n";
+ $SQLid="SELECT MIN(`UID`) FROM `UserCVS`;";
+ $Erg = mysql_query( $SQLid);
+
+ if( mysql_num_rows($Erg) == 1) {
+ $NewId = mysql_result( $Erg, 0, 0)-1;
+ $SQLnew1 = "INSERT INTO `UserGroups` (`UID`, `Name`) VALUES ('$NewId', '". $_POST["GroupName"]. "' );";
+ $SQLnew2 = "INSERT INTO `UserCVS` (`UID`, `GroupID`) VALUES ('$NewId', NULL );";
+ echo "\t<br />Generate new UserGroup ...\n";
+ $ErgNew1 = db_query($SQLnew1, "create UserGroups Entry");
+ if ($ErgNew1 == 1)
+ {
+ echo "\t<br />Generate new User rights...\n";
+ $ErgNew2 = db_query($SQLnew2, "UserCVS Entry");
+ if ($ErgNew1 == 1) {
+ echo "\t<br />New group was created.\n";
+ } else {
+ echo "Error on creation\n(". mysql_error($con). ")";
+ }
+ } else {
+ echo "Error on creation\n(". mysql_error($con). ")";
+ }
- }
+ }
-
- break;
- }
+
+ break;
+ }
} else {
- // kein Action gesetzt -> abbruch
- echo "Unzul&auml;ssiger Aufruf.<br>Bitte neu editieren...";
+ // kein Action gesetzt -> abbruch
+ echo "Unzul&auml;ssiger Aufruf.<br />Bitte neu editieren...";
}
include ("../../../camp2011/includes/footer.php");