Skip to content

Examples

ConnorC18 edited this page Mar 24, 2019 · 5 revisions

Python Authentication Library Examples

Contents

Functions

Load Library
from loginSystem import * # Loads the login library
Sign Up
signup() # Will return True or the error message thrown by the function
Login
login() # Will return True or "incorrectinfo" or "noaccount" depending on the error.
Check If User Is Logged In
checkLoggedIn() # Will return True of False
Reset Password
passwordReset() # Will return True or "noemail" or "wrongsecurityquestionanswer"
Session Info
print(sessionInfo["username"]) # Will return the current logged in users, username
Logout
print(logout())  # Will return True or "notloggedin"

Usage

WRITE LIKE: IF STATMENTS AND STUFF

Clone this wiki locally