PHP Admin Panel is a lightweight, ready-to-extend admin dashboard template built with PHP, Bootstrap 5, and AdminLTE 3. It provides a data-driven sidebar menu, a breadcrumb-aware page header, stat cards, and a SweetAlert2-powered logout confirmation β a clean starting point for building your own admin backend on top of it.
- Features
- Installation
- Adding Sidebar Menu Items
- Project Structure
- Technologies Used
- License
- Contributing
- Connect with Me
β
Data-Driven Sidebar β Menu items and pages are defined in a single PHP array, no hardcoded HTML.
β
Automatic Breadcrumbs β The current page's breadcrumb and active menu state are resolved automatically.
β
Dashboard Stat Cards β Ready-made AdminLTE "small box" widgets for at-a-glance metrics.
β
Profile Page β A dedicated profile.php page wired into the same layout.
β
Logout Confirmation β SweetAlert2 confirmation dialog before logging out.
β
Shared Layout β header.php and footer.php keep every page consistent with one include.
git clone https://github.com/Iqbolshoh/php-admin-panel.git
cd php-admin-panelUse any PHP-compatible server (Apache, Nginx, XAMPP, WAMP, MAMP) and place the project files in the server's root directory (htdocs/www), or run PHP's built-in server:
php -S localhost:8000http://localhost:8000
The $menuItems array in header.php defines the sidebar. Each entry includes:
β
menuTitle β The section name (e.g. "Dashboard").
β
icon β The section icon (e.g. "fas fa-home").
β
pages β Subpages, each with a "title" and a "url".
$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"]
],
]
];The active menu item and breadcrumb trail are resolved automatically by matching the current page's filename against this array.
php-admin-panel/
βββ header.php # <head>, navbar, sidebar, and $menuItems config
βββ footer.php # Closing markup + logout confirmation script
βββ index.php # Dashboard page (stat cards)
βββ profile.php # Profile page
βββ src/images/ # Banner, logo, and profile picture assets
This project is open-source and available under the MIT License.
π― 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:
