thommy1972de

Untitled

Apr 7th, 2022
795
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.51 KB | None | 0 0
  1. namespace Funktionen;
  2.  
  3.  
  4. class PASSWORT_VERGESSEN_NEU
  5. {
  6.  
  7.     function EmailCheck($email, $pdo)
  8.     {
  9.         $email_suche = $pdo->query("SELECT * FROM user WHERE email = '" . $email . "' LIMIT 1");
  10.         $email_suche->execute();
  11.         return $email_suche->rowcount();
  12.     }
  13.  
  14.  
  15.     function generateRandomString($length = 30)
  16.     {
  17.         $alphabet = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
  18.         return substr(str_shuffle(str_repeat($alphabet, $length)), 0, $length);
  19.     }
  20. }
Advertisement
Add Comment
Please, Sign In to add comment