# Opti-Vision Eye Clinic Website
A complete professional eye clinic website built with PHP, MySQL, Bootstrap, and modern web technologies.
## Features
### 🏥 **Complete Eye Clinic Management System**
- **User Registration & Authentication** - Secure login/register system
- **Appointment Booking** - Easy online appointment scheduling
- **User Dashboard** - Personal dashboard for patients
- **Admin Dashboard** - Complete management system for administrators
- **Service Management** - Manage eye care services and pricing
- **Doctor Profiles** - Showcase medical professionals
- **Contact System** - Contact form with message management
### 🎨 **Modern Design & UX**
- **Responsive Design** - Works perfectly on all devices
- **Bootstrap 5** - Modern, clean interface
- **Professional UI** - Medical-grade design standards
- **Fast Loading** - Optimized for speed and performance
- **Accessibility** - User-friendly for all visitors
### 🔧 **Technical Features**
- **PHP 7.4+** - Server-side scripting
- **MySQL Database** - Reliable data storage
- **PDO Security** - SQL injection protection
- **Session Management** - Secure user sessions
- **Form Validation** - Client and server-side validation
- **Error Handling** - Comprehensive error management
## Installation
### Prerequisites
- PHP 7.4 or higher
- MySQL 5.7 or higher
- Web server (Apache/Nginx)
- Composer (optional)
### Setup Instructions
1. **Clone/Download the project**
```bash
git clone [repository-url]
cd eye-clinic-website
```
2. **Database Setup**
- Create a new MySQL database named `eye clinic website`
- Import the `database_setup.sql` file to create tables and sample data
- Default admin credentials:
- Email: `admin@eyeclinic.com`
- Password: `password`
3. **Configure Database Connection**
- Edit `config/database.php` if needed
- Default settings:
- Host: `localhost`
- Database: `eye clinic website`
- Username: `root`
- Password: (empty)
4. **Set Permissions**
```bash
chmod 755 assets/images/
chmod 755 assets/images/doctors/
```
5. **Access the Website**
- Open your browser and navigate to the project directory
- The website should be fully functional
## File Structure
```
eye-clinic-website/
├── admin/ # Admin panel files
│ ├── dashboard.php # Admin dashboard
│ ├── appointments.php # Manage appointments
│ └── ...
├── user/ # User panel files
│ ├── dashboard.php # User dashboard
│ ├── profile.php # User profile
│ └── ...
├── assets/ # Static assets
│ ├── css/ # Stylesheets
│ ├── js/ # JavaScript files
│ └── images/ # Images and media
├── config/ # Configuration files
│ └── database.php # Database connection
├── includes/ # Common includes
│ └── auth.php # Authentication functions
├── index.php # Homepage
├── login.php # Login page
├── register.php # Registration page
├── appointment.php # Appointment booking
├── services.php # Services page
├── doctors.php # Doctors page
├── contact.php # Contact page
├── about.php # About page
└── database_setup.sql # Database setup script
```
## Usage
### For Patients
1. **Register** - Create a new account
2. **Login** - Access your dashboard
3. **Book Appointment** - Schedule eye care services
4. **View History** - Check appointment history
5. **Update Profile** - Manage personal information
### For Administrators
1. **Login** - Use admin credentials
2. **Dashboard** - View system overview
3. **Manage Appointments** - Confirm/cancel appointments
4. **User Management** - View registered users
5. **Service Management** - Add/edit services
6. **Doctor Management** - Manage doctor profiles
## Database Schema
### Tables
- **users** - User accounts and authentication
- **services** - Eye care services and pricing
- **appointments** - Appointment bookings
- **doctors** - Medical professional profiles
- **contact_messages** - Contact form submissions
## Customization
### Adding New Services
1. Access admin dashboard
2. Go to Services management
3. Add new service with title, description, and price
### Modifying Design
- Edit `assets/css/style.css` for styling changes
- Update color scheme in CSS variables
- Modify Bootstrap components as needed
### Adding Features
- Extend database schema as needed
- Add new PHP files following existing patterns
- Update navigation menus accordingly
## Security Features
- **Password Hashing** - Secure password storage
- **SQL Injection Protection** - PDO prepared statements
- **Input Validation** - Server-side validation
- **Session Security** - Secure session management
- **XSS Protection** - Input sanitization
## Browser Support
- Chrome 90+
- Firefox 88+
- Safari 14+
- Edge 90+
## Performance Optimization
- **Minified CSS/JS** - Reduced file sizes
- **Optimized Images** - Compressed media files
- **Database Indexing** - Fast query performance
- **Caching Headers** - Browser caching support
## Support
For technical support or questions:
- Email: support@optivision.com
- Phone: +92 300 1234567
## License
This project is proprietary software. All rights reserved.
## Changelog
### Version 1.0.0
- Initial release
- Complete eye clinic management system
- User and admin dashboards
- Appointment booking system
- Responsive design
- Database integration
---
**Developed with ❤️ for Opti-Vision Eye Clinic**