Refactor contact management functions and remove phpinfo.php

- Updated formatting and structure of functions in edit_contact.inc.php for better readability and consistency.
- Added comments to clarify the purpose of certain code sections, especially regarding mandant handling.
- Removed the deprecated phpinfo.php file to clean up the codebase.
This commit is contained in:
2026-05-11 08:54:44 +02:00
parent 8749bc7994
commit 52ca9249c3
64 changed files with 13445 additions and 3562 deletions

View File

@@ -46,6 +46,21 @@ function mysqli_result( $res, $row = 0, $col = 0 ) {
return FALSE;
}
function encryptId($id)
{
$encryptedId = base64_encode($id . "EC1ibm38FI53cxmSnQUi");
return $encryptedId;
}
// Entschlüsselt eine zuvor verschlüsselte ID, um ihre ursprüngliche Form wiederherzustellen.
function decryptId($encryptedId)
{
$decryptedId = base64_decode($encryptedId);
$id = str_replace("EC1ibm38FI53cxmSnQUi", "", $decryptedId);
return $id;
}
// Verbindung mir der Datenbank herstellen
function db_connect() {
$servername = $GLOBALS['myservername'];
@@ -57,6 +72,9 @@ function db_connect() {
@mysqli_select_db($GLOBALS['mysql_con'], $db) or die (mysqli_error($GLOBALS['mysql_con']) . " - Keine Verbindung hergestellt!");
@mysqli_query($GLOBALS['mysql_con'], "set character set 'utf8';");
@mysqli_query($GLOBALS['mysql_con'], "set names 'utf8';");
$pdo = new PDO('mysql:host='.$servername.';dbname='.$db, $login, $pass);
$GLOBALS['pdo_conn'] = $pdo;
}
// Globales führen der Reihenfolge in der Felder angewählt werden