A modern, responsive bus ticketing website built with HTML, Tailwind CSS, and JavaScript. This platform allows users to browse bus routes, select seats, apply coupons, and book tickets seamlessly.
- Seat Selection System - Interactive seat map with real-time availability
- Smart Pricing - Dynamic price calculation with discount coupons
- Responsive Design - Mobile-first approach works on all devices
- Booking Management - Complete booking flow with passenger details
- Modern UI/UX - Clean, intuitive interface with smooth animations
- Real-time Updates - Instant price calculation and seat status
- Coupon System - Support for promotional discounts (NEW15, COUPLE20)
- Form Validation - Comprehensive client-side validation
- Hero Section - Compelling banner with call-to-action
- Statistics - Company achievements and trust indicators
- Special Offers - Promotional coupons and discounts
- Popular Destinations - Featured routes across Bangladesh
- Why Choose Us - Key differentiators and benefits
- Testimonials - Customer reviews and ratings
- Ticket Booking - Complete booking interface
- Footer - Company information and links
- Frontend: HTML5, Tailwind CSS, DaisyUI
- JavaScript: Vanilla ES6+
- Icons: Emoji-based (no external dependencies)
- Font: Raleway (Google Fonts)
- Responsive: Mobile-first CSS Grid and Flexbox
matha-paribahan/
βββ index.html # Main HTML file
βββ style.css # Custom styles and animations
βββ script.js # JavaScript functionality
βββ images/ # Asset directory
β βββ banner.png
β βββ bus-icon.png
β βββ ...
βββ README.md # Project documentation
βββ screenshots/ # Project screenshots
- Modern web browser (Chrome, Firefox, Safari, Edge)
- Local server for development (optional)
-
Clone the repository
git clone https://github.com/developerMohib/smart-ticketing-A5.git cd matha-paribahan -
Open in browser
simply open index.html in your browser -
Start developing
- Modify
index.htmlfor structure changes - Update
style.cssfor styling - Enhance
script.jsfor functionality
- Modify
- Browse Destinations - View popular routes and pricing
- Select Seats - Choose from available seats on the interactive map
- Apply Coupons - Use discount codes for savings
- Fill Details - Enter passenger information
- Confirm Booking - Complete the reservation process
- The project uses Tailwind CSS utility classes
- Custom CSS extends Tailwind in
style.css - JavaScript handles all interactive functionality
- Emoji icons are used for better performance
Edit the Popular Destinations section in index.html:
The project includes a custom Tailwind configuration:
tailwind.config = {
theme: {
extend: {
colors: {
// Custom color palette
},
fontFamily: {
raleway: ["Raleway", "sans-serif"],
},
},
},
};Key configuration variables in script.js:
const maxSeats = 4; // Maximum seats per booking
const seatPrice = 550; // Base price per seat
const couponCodes = {
// Available discount coupons
NEW15: 0.15, // 15% discount
COUPLE20: 0.2, // 20% discount
};- Mobile: < 768px
- Tablet: 768px - 1024px
- Desktop: > 1024px
- Chrome 90+
- Firefox 88+
- Safari 14+
- Edge 90+
- Semantic HTML5 structure
- Accessible markup with proper ARIA labels
- SEO-optimized meta tags
- Responsive design patterns
- Custom utility classes
- Animation keyframes
- Responsive breakpoints
- Print styles
- Modular function organization
- Event delegation
- Form validation
- Local state management
- New Section Template
<section class="py-12 bg-white">
<div class="container">
<div class="text-center mb-12">
<h2 class="text-3xl md:text-4xl font-bold text-secondary">
Section Title
</h2>
</div>
<!-- Section content -->
</div>
</section>- New JavaScript Function
function newFeature() {
// Implementation here
}
// Initialize in DOMContentLoaded
document.addEventListener("DOMContentLoaded", function () {
newFeature();
});- Load Time: Optimized with minimal external dependencies
- SEO: Semantic HTML and proper meta tags
- Accessibility: WCAG 2.1 compliant
- Progressive Enhancement: Core functionality works without JavaScript
We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow existing code style
- Test on multiple devices and browsers
- Update documentation for new features
- Ensure responsive design principles
-
Seat selection not working
- Check JavaScript console for errors
- Verify
bus-seatclass is applied to buttons
-
Styles not loading
- Ensure Tailwind CSS CDN is accessible
- Check custom CSS file path
-
Coupons not applying
- Verify coupon codes are uppercase
- Check minimum seat requirement (2 seats)
Enable console logging by adding:
const DEBUG = true;- Tailwind CSS for utility-first CSS
- DaisyUI for component library
- Google Fonts for Raleway font
For support and questions:
- π§ Email: [email protected]
- π Issue Tracker
- π¬ Discussions
- Initial release
- Complete booking system
- Responsive design
- Coupon functionality
- User authentication
- Payment integration
- Admin dashboard
- Mobile app
- Real-time tracking
Built with β€οΈ for Bangladesh's transportation needs
Matha Paribahan - Your Journey, Our Responsibility