A full-stack web application built using Java (JSP, Servlets), JDBC, and MySQL. The project allows users to browse and order food, while admins can manage menu items, categories, and orders.
The goal of this project is to develop a user-friendly online food ordering system that streamlines the process of browsing menus, placing orders, and managing food items. It aims to bridge the gap between restaurants and customers through a digital platform, offering convenience, efficiency, and real-time order management for both users and administrators.
- Backend: Java, JSP, Servlets, JDBC
- Frontend: HTML, CSS, JavaScript, Bootstrap
- Database: MySQL
This project follows the MVC (Model-View-Controller) architecture:
- Model: Java classes representing data entities like
User
,FoodItem
,Order
, etc. - View: JSP files used for rendering the frontend interface for users and admins.
- Controller: Servlets handling the business logic and routing requests between the view and model.
- Register and login
- Browse food items by category
- Add items to cart
- Place orders
- View order history
- Login securely
- Manage categories and food items (CRUD)
- View and manage customer orders
- Login/Signup with session management
- Role-based access (admin and user dashboards)
- Dynamic loading of food items and categories
- Responsive UI with Bootstrap
- Secure JDBC with Prepared Statements
- POJO model for data abstraction
- MVC pattern for separation of concerns
- Company
- Contact
- Login
- Registration
- Menus
- Profile
- Order History
- Add Food
- All Order
- Menus
OnlineFoodApp/
β
βββ src/
β βββ main/
β βββ java/
β β βββ com.onlinefood/
β β βββ controller/ # Servlets (Controllers)
β β βββ dao/ # Database logic (Data Access Objects)
β β βββ model/ # Models
β β βββ utils/ # DB connection, helpers
β βββ webapp/
β βββ css/ # Stylesheets
β βββ js/ # JavaScript files
β βββ admin/ # Admin dashboard views
β βββ user/ # User dashboard views
β βββ images/ # Image assets
β βββ index.jsp # Homepage
β βββ login.jsp # Login page
βββ README.md
STEP 1: Open MySQL Command Prompt or MySQL Workbench
STEP 2: Login to the administrator user of MySql:
mysql -u <username> -p
(Enter Password if asked)
STEP 3: Copy paste and execute the MySQL Query from the following file:-
- Run the Sql Query From this file: MySQL Database
π GitHub: https://github.com/pratikkhot100
πΌ LinkedIn: https://www.linkedin.com/in/pratikkhot01
π§ Email: [email protected]