diff --git a/homepage/mams/.htaccess b/homepage/mams/.htaccess
new file mode 100644
index 0000000..34b4883
--- /dev/null
+++ b/homepage/mams/.htaccess
@@ -0,0 +1,6 @@
+AuthType Basic
+AuthName "tempDirectory"
+AuthUserFile /users/cwsvjudo/www/.htusers
+#AuthGroupFile /users/cwsvjudo/www/.htgroups
+Require user marko
+#Require group admin
diff --git a/homepage/mams/index.php b/homepage/mams/index.php
new file mode 100644
index 0000000..3d2eff6
--- /dev/null
+++ b/homepage/mams/index.php
@@ -0,0 +1,64 @@
+
+
+
+
+ $attendees);{
+ echo("".$date."
");
+ echo("");
+ echo("");
+ echo("| name | ");
+ echo("vorname | ");
+ echo("PLZ | ");
+ echo("Telefon | ");
+ echo("eMail | ");
+ echo("
");
+ foreach($attendees as $a){
+ echo("");
+ echo("| ".$a[0]['name']." | ");
+ echo("".$a[0]['vorname']." | ");
+ echo("".$a[0]['corona_PLZ']." | ");
+ echo("".$a[0]['corona_telephon']." | ");
+ echo("".$a[0]['corona_eMail']." | ");
+ echo("
");
+ }
+ echo("
");
+ }
+ ?>
+
+
diff --git a/homepage/mams/lib/db.php b/homepage/mams/lib/db.php
new file mode 100644
index 0000000..e00cd2d
--- /dev/null
+++ b/homepage/mams/lib/db.php
@@ -0,0 +1,126 @@
+getMessage() );
+ }
+return $dbConnection;
+}
+
+function createDb($dbConnection){
+<< array('value'=>$anUserId, 'data_type'=>PDO::PARAM_INT),
+/// ':attributeId'=> array('value'=>$anAttributeId, 'data_type'=>PDO::PARAM_INT) )
+/// @param $someOption
+function dbQuery($aDbConnection, $aQueryString, $aBindArray = array(), $someOptions = array()){
+// Standardbelegungen
+if( empty($someOptions['dbCharset' ]) ) $someOptions['dbCharset' ] = "ISO-8859-1";
+if( empty($someOptions['outCharset']) ) $someOptions['outCharset'] = "UTF-8";
+if( empty($someOptions['dontFetch' ]) ) $someOptions['dontFetch' ] = false;
+/// @toDo: Bisher wird nur die Rückgabe konvertiert. Eigentlich muss
+/// doch auch die Eingabe konvertiert werden. Aber das jetzt
+/// umzustellen wird schwer! Die User m Wettkampfplaner sind ja z.B.
+/// als UTF8 in latin1(?) gespeichert.
+/// @toDo: Die Standardwerte sollten vielleicht aus einer config
+/// kommen, nicht hardcoded
+ try{
+ $pdoStatement = $aDbConnection->prepare( $aQueryString );
+ foreach( $aBindArray as $bindName => $bind ){
+ $pdoStatement->bindValue(
+ $bindName,
+ $bind['value'],
+ (isset($bind['data_type'])?$bind['data_type']:PDO::PARAM_STR)
+ );
+ }
+ $pdoResult = $pdoStatement->execute();
+
+ //if(!$pdoResult)
+ //echo("Strange! \"".$aQueryString."\" failed without exception!");
+
+ if($someOptions['dontFetch']){
+ $ret = NULL;
+ }
+ else{
+ $ret = $pdoStatement->fetchAll(PDO::FETCH_ASSOC);
+ }
+ }
+ catch(PDOException $db_error){
+ print "Error!: " . $db_error->getMessage() . "
";
+ return null;
+ }
+// Zeichensatzkonvertierung
+ if( is_array($ret) ){
+ foreach($ret as &$entry){
+ array_walk(
+ $entry,
+ function (&$value, $key, $someOptions) {
+ $value = iconv($someOptions['dbCharset'], $someOptions['outCharset'], $value);
+ },
+ $someOptions
+ );
+ }
+ }
+return $ret;
+}
+
+function getLastAttendances($db){
+ $query = <<userAttributes`
+ ON `cwsvjudo`.`wkParticipo_Users`.`id` =`cwsvjudo`.`wkParticipo_user<=>userAttributes`.`userId`
+WHERE `cwsvjudo`.`wkParticipo_user<=>userAttributes`.`attributeId` IN (
+ SELECT `id` FROM `cwsvjudo`.`wkParticipo_userAttributes` WHERE `name` = :attributeName
+);
+SQL;
+ $params = array(
+ ':attributeName' => array('value'=>$attributeName, 'data_type'=>PDO::PARAM_STR)
+ );
+return dbQuery($dbConnection, $query, $params);
+}
+
+function giveJudokasAttendence($dbConnection, $date, $ids){
+ $values = array();
+ foreach( $ids as $id){
+ array_push( $values, "(\"".$date."\", ".$id.")");;
+ }
+ $query = "INSERT INTO `cwsvjudo`.`anwesenheit` (`date`, `userId`) VALUES ".join(",", $values).";";
+ dbQuery($dbConnection, $query, array(), ['dontFetch' => true]);
+}
+?>
diff --git a/homepage/mams/local/cwsvJudo.config.php b/homepage/mams/local/cwsvJudo.config.php
new file mode 100644
index 0000000..3998c08
--- /dev/null
+++ b/homepage/mams/local/cwsvJudo.config.php
@@ -0,0 +1,6 @@
+