Skip to content

A comprehensive web-based library management system built with PHP and MySQL that allows students to borrow books, manage their accounts, and enables administrators to manage the library inventory.

Notifications You must be signed in to change notification settings

psenjenk/library-management-system-LMS

Repository files navigation

Online Library Management System

A comprehensive web-based library management system built with PHP and MySQL that allows students to borrow books, manage their accounts, and enables administrators to manage the library inventory.

Features

For Students

  • User registration and authentication
  • Secure login with rate limiting and CSRF protection
  • View available books
  • Borrow and return books
  • View issued books history
  • Profile management
  • Password recovery system

For Administrators

  • Admin dashboard
  • Book management (add, edit, delete)
  • Category management
  • Author management
  • Student account management
  • Issue/return book tracking
  • Fine calculation for late returns

Technical Stack

  • Frontend: HTML5, CSS3, Bootstrap, jQuery
  • Backend: PHP
  • Database: MySQL
  • Server: Apache (XAMPP)

Project Structure

library/
├── admin/              # Admin panel files
├── assets/            # Static assets (CSS, JS, images)
├── includes/          # Common PHP includes
├── error/            # Error handling files
├── logs/             # Application logs
├── .env              # Environment configuration
├── .htaccess         # Apache configuration
├── index.php         # Main entry point
├── library.sql       # Database schema
└── various PHP files # Core application files

Database Schema

The system uses the following main tables:

  • admin - Administrator accounts
  • tblstudents - Student user accounts
  • tblbooks - Book inventory
  • tblauthors - Author information
  • tblcategory - Book categories
  • tblissuedbookdetails - Book borrowing records

Setup Instructions

  1. Prerequisites

    • XAMPP (Apache, MySQL, PHP)
    • Web browser
  2. Installation

    • Clone or download this repository to your XAMPP's htdocs directory
    • Create a new MySQL database named library
    • Import the library.sql file into your database
    • Configure your database connection in includes/config.php
  3. Configuration

    • Update the .env file with your database credentials
    • Ensure proper permissions are set on the logs directory
  4. Access

    • Start your XAMPP server
    • Access the application through: http://localhost/library
    • Default admin credentials:
      • Username: admin
      • Password: admin123

Security Features

  • Password hashing
  • CSRF protection
  • Rate limiting for login attempts
  • Input sanitization
  • Session management
  • SQL injection prevention using prepared statements

Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a new Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For support, please contact the system administrator or create an issue in the repository.

About

A comprehensive web-based library management system built with PHP and MySQL that allows students to borrow books, manage their accounts, and enables administrators to manage the library inventory.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published