Welcome to the official web platform for the National Beer Basketball League. Born from some of the lads just trying to get hydrated and have fun doing so, the NBBL has evolved into a competitive yet social league where the love of the game meets the appreciation of a cold beverage.
This is a full-stack PHP web application designed to manage league standings, player profiles, and community news. It features a custom-built authentication system, a secure administrative back-end, and automated email notifications.
- Dynamic Profiles: Users can create accounts, track their career wins, and share an "About Me" bio.
- Image Uploads: Custom profile picture support using unique file naming to prevent server-side overwrites.
- Preference Management: Integrated "Unsubscribe" functionality giving users control over league emails.
- Responsive Design: Fully themed with Light and Dark mode support via CSS variables.
- Score Management: A mobile-optimized "card-style" interface allowing admins to quickly update league wins from the court.
- Newsletter System: Admins can blast news updates to all subscribed players with professional HTML-formatted emails.
- Role-Based Security: Strict server-side checks ensure only authorized admins can access management tools.
- Language: PHP 8.x
- Database: MySQL (interfaced via PDO for SQL injection protection)
- Security: * Password hashing via
password_hash().- Sensitive credentials stored outside the web root.
- Sanitization and validation helpers for all user inputs.
- Styling: Modern CSS3 with Flexbox, Grid, and Media Queries.
├── www-root/ # Publicly accessible files
│ ├── css/ # Style sheets (Theme & Grid logic)
│ ├── images/ # Static assets and player uploads
│ ├── includes/ # Navigation, Footer, and Config helpers
│ ├── index.php # League Landing Page
│ └── ... # Functional pages (Login, Account, News)
└── db_config/ # SECURE: Database credentials (outside web root)
- Database Migration: Import the provided SQL schema to create the
playersandnewstables. - Credential Configuration: Place your
database-config.phpin a folder nameddb_configone level above your web root. - Permissions: Ensure the
images/directory is writable (chmod 755) for profile picture uploads. - Admin Setup: Manually toggle the
is_adminbit to1in the database for your primary account.
Developed by: Nicolas Fay
Computer Science @ The University of Vermont