This repository is a user authentication and role management system built with PHP. It provides an easy-to-use admin panel and allows the creation and management of multiple user roles. Security is the top priority in PHP Auth Master, ensuring user data is well-protected.
- πΉ Multiple User Roles β Easily manage Admin, User, and more.
- πΉ Admin Panel β Built-in dashboard for role & permission control.
- πΉ Secure Authentication β Password hashing & session protection.
- πΉ Role-Based Access β Restrict pages based on user roles.
- πΉ Auto Menu Generation β Dynamic navigation for admin panel.
- πΉ Advanced Security β Active session tracking & auto logout on password change.
β
Secure β Tracks active sessions & prevents unauthorized access.
β
Easy to Use β Simple admin panel for quick management.
β
Scalable β Add new roles & users effortlessly.
β
Real-Time Control β Monitor & remove active sessions anytime.
- π₯ Admin Login:
iqbolshoh
- π€ User Login:
user
- π Password:
IQBOLSHOH
Admin can view and update their profile. They can also access system settings and manage various administrative functions.
Admin can view all users and create multiple new users. They have full control over user management and permissions.
Users can view and update their profile. They can also access available features
Creating a menu in the admin panel is super easy! Just define the menu structure, and the system will automatically generate the necessary navigation and pages for you. π
Hereβs a simple example:
$menuItems = [
[
"menuTitle" => "Dashboard",
"icon" => "fas fa-tachometer-alt",
"pages" => [
["title" => "Home", "url" => "index.php"]
],
],
[
"menuTitle" => "Settings",
"icon" => "fas fa-cog",
"pages" => [
["title" => "Profile", "url" => "profile.php"],
["title" => "Active Sessions", "url" => "active_sessions.php"]
],
]
];
π No need for manual codingβjust define your menu items, and the system takes care of the rest! π
Get PHP Auth Master running in just two steps!
git clone https://github.com/Iqbolshoh/php-auth-master.git
cd php-auth-master
mysql -u yourusername -p yourpassword < database.sql
πΉ Replace yourusername
& yourpassword
with your MySQL credentials.
Just edit config.php
to set up the database:
define("DB_SERVER", "localhost");
define("DB_USERNAME", "root");
define("DB_PASSWORD", "");
define("DB_NAME", "auth_master");
π Adding Roles? Just update ROLES
βthe system handles the rest! π
const ROLES = [
'admin' => '/admin/',
'user' => '/',
'manager'=>'/manager/' // Add role
];
π― Contributions are welcome! If you have suggestions or want to enhance the project, feel free to fork the repository and submit a pull request.
π¬ I love meeting new people and discussing tech, business, and creative ideas. Letβs connect! You can reach me on these platforms: