Practical PHP and MySQL
Chapter 8
The entire chapter is about building a calendar application.
Exercise
- Calendar App (calendar)
- This won't work on my server because of session issues, so view it on the school's servers. I'm happy to announce that this site works perfectly. No issues at all, that I could find. Plus, I added some functionality to it.
User Login:
Username: user
Password: pass
What I Added, In No Particular Order
- Multi-user functionality
- Registration form
- Title displays name or username (if name not added)
- Accessibility tweaks
- Added titles in links to:
- Shortened links: includes full name of event plus start & end times in 12 hour format
- Delete event links: includes "Delete" plus event name
- Month navigation: includes "Previous/Next month"
- Invisible "add event" links within table: includes "Make new event"
- Added titles in links to:
- Usability tweaks
- Added "back" link to event detail
- Added "cancel" link to new event form
- Added "delete event" link to event in side bar
- General Look & Feel Updates
- Previous/next month padding cells have unique background
- Previous month padding cells now have dates (next month had them automatically)
- All start/end times are in 12-hour format, including "add new event" form
- Sidebar displays all events from the current day onward, regardless of event start times
- Ordered events within the calendar to appear from earliest to latest, instead of addition order
- Made cells align vertically to the top
- Made calendar total width dependant on screen size
- Shortened event name trucation to account for lowest common screen size
- Ellipses conditional on length of trucation (no truncation, no ellipsis)
- Changed all preview dates to American format (vs. MySQL format)
- Made entire cell change color vs. just link area
- Kept area around event stay white on rollover