WIP: bring participo back - consistent use of bootstrap - formatting -
phpstan level 0 error free - fixes for kyu subpage - move mams into participo framework - remove legacy `lib/db.php` usage - add attributer admin function - add newsposter - fixing apiKey creation
This commit is contained in:
@@ -1,32 +1,24 @@
|
||||
<?php
|
||||
// (local specific) settings
|
||||
require_once 'local/cwsvJudo.php';
|
||||
require_once 'config/participo.php';
|
||||
require_once "config.php";
|
||||
require_once "bootstrap.php";
|
||||
|
||||
require_once "participoLib/dbConnector.php";
|
||||
require_once "participoLib/participo.php";
|
||||
require_once "participoLib/user.php";
|
||||
|
||||
require_once 'participoLib/dbConnector.php';
|
||||
require_once 'participoLib/participo.php';
|
||||
require_once 'participoLib/user.php';
|
||||
participo::init(config: $CONFIG["cwsvJudo"], secrets: $SECRETS["cwsvJudo"]);
|
||||
|
||||
dbConnector::connect(
|
||||
$cwsvJudoConfig['db']['host'],
|
||||
$cwsvJudoConfig['db']['name'],
|
||||
$cwsvJudoConfig['db']['user'],
|
||||
$cwsvJudoConfig['db']['password']
|
||||
);
|
||||
$loginName = $_POST["loginName"] ?? null;
|
||||
$name = $_POST["name"] ?? null;
|
||||
$firstName = $_POST["firstName"] ?? null;
|
||||
$dateOfBirth = $_POST["dateOfBirth"] ?? null;
|
||||
$eMail = $_POST["eMail"] ?? "";
|
||||
|
||||
participo::authentificate();
|
||||
|
||||
$loginName = $_POST['loginName'] ?? null;
|
||||
$name = $_POST['name'] ?? null;
|
||||
$firstName = $_POST['firstName']??null;
|
||||
$dateOfBirth = $_POST['dateOfBirth']??null;
|
||||
$eMail=$_POST['eMail']?? null;
|
||||
|
||||
$returnToUrl = $_POST['returnToUrl'] ?? 'participo/';
|
||||
$returnToUrl = $_POST["returnToUrl"] ?? "participo/";
|
||||
|
||||
$newUser = new User(null, $loginName, $name, $firstName, $dateOfBirth, $eMail);
|
||||
$newUserId = $newUser->addToDb();
|
||||
|
||||
header('Location: ' . urldecode($returnToUrl), true, 301);
|
||||
header("Location: " . urldecode($returnToUrl), true, 301);
|
||||
exit(-1); // shouldn't matter
|
||||
|
||||
Reference in New Issue
Block a user