Status: Archived — Not Actively Maintained
Part of my course work
The Car Booking Website is a full-stack web application developed as part of a university project. It allows users to browse, book, and pay for car rentals online through secure payment integrations.
The system supports both Stripe and M-Pesa Daraja API for payment processing, providing flexibility for international and local users.
| Layer | Technology |
|---|---|
| Frontend | HTML, CSS, JavaScript |
| Backend | PHP (Procedural / OOP) |
| Database | MySQL |
| Server Environment | XAMPP (Apache + MySQL + PHP) |
| Payment Integration | M-Pesa Daraja API, Stripe API |
- 🔐 User Authentication: Sign-up, Login, and Logout system
- 🚘 Car Listings: Display cars with details (model, rate, availability)
- 📅 Booking System: Users can book cars for selected dates and durations
- 💳 Secure Payments:
- M-Pesa Daraja API integration for local mobile payments
- Stripe API integration for international card payments
- 🧾 Booking Management: Users can view and manage their booking history
- 🧑💻 Admin Panel: Add, edit, or remove car listings and manage users
- 📱 Responsive Design: Works on both mobile and desktop screens
git clone https://github.com/yourusername/Moti.git
Place the project folder inside:
C:\xampp\htdocs\
- Start XAMPP (Apache + MySQL)
- Go to phpMyAdmin
- Create a new database (carrental)
- Import the SQL file provided in:
/db name/carrental.sql
Open config.php and set your credentials:
define('DB_HOST','localhost');
define('DB_USER','root');
define('DB_PASS','');
define('DB_NAME','carrental');
You’ll need to obtain your API credentials from the respective developer platforms before running the payment integrations.
Note: For local testing of M-Pesa Daraja, you may need to use sandbox credentials and Ngrok to expose callback URLs.
Open your browser and visit:
Working with PHP & MySQL to create dynamic web apps
Implementing payment gateways (M-Pesa Daraja & Stripe)
Designing and validating booking systems
Building a responsive and user-friendly interface
Understanding session handling, database queries, and API integration
This project was created for educational purposes and is no longer maintained. Security practices and dependencies may be outdated. Use for reference or learning only.
Erick Wambua