added own random file
This commit is contained in:
parent
e887951cee
commit
61e9819053
2 changed files with 22 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
|||
<div>
|
||||
<h1>LOGIN</h1>
|
||||
<h1>Auth LOGIN</h1>
|
||||
<form class="w3-form" action="login.php" method="post">
|
||||
<label for="uid">Benutzer Id oder E-Mail:</label><br>
|
||||
<input type="text" id="uid" name="uid" required><br>
|
||||
|
|
21
random.php
Normal file
21
random.php
Normal file
|
@ -0,0 +1,21 @@
|
|||
<?php
|
||||
|
||||
/*
|
||||
* smzint/Auth (c) schmamazon.com 2025
|
||||
*/
|
||||
|
||||
function generateRandomString($length = 32) {
|
||||
$characters = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ';
|
||||
$charactersLength = strlen($characters);
|
||||
$randomString = '';
|
||||
|
||||
for ($i = 0; $i < $length; $i++) {
|
||||
$randomString .= $characters[random_int(0, $charactersLength - 1)];
|
||||
}
|
||||
|
||||
return $randomString;
|
||||
}
|
||||
|
||||
|
||||
|
||||
?>
|
Loading…
Add table
Reference in a new issue