Practical Databases

  • Admin panel
  • Image upload
  • Stock Control
  • Order system

A front and backend system built in PHP for a movie rental business, inc multiple data cardinalities

Dashboard of the app BB
  • Twig logo


  • PHP language logo


  • Slim PHP logo

    Slim PHP

  • MySQL logo


It's back... busters

For this module, we were tasked to design a system that should include a number of prerequisites.

Key Features:

  • All database tables in 3rd normal form
  • Every table should have at least 4 attributes
  • The database should include all cardinalities:
    • one-to-one
    • one-to-many
    • many-to-many
  • The database should include all participation constraints:
    • mandatory
    • optional
  • Have at least 2 user roles with a login system restricting views
  • Include MySQL views:
    • Self Joins
    • Inner Joins
    • Outer Joins
    • Explicit Joins
    • Implicit Joins

With that said, working almost backwards was quite difficult in some ways (mainly the database constraints) as one would usually research the business/system requirements from which to develop the database from. However, after discussing it with the lecturer, I decided to build a system similar to those used at a Blockbuster, one which allows staff and admin to rent movies to customers in a brick and mortar store.

Database system entity relationship diagram showing tables in third normal form, including cardinalities

Big Boss

To help in the development of the system, we were allowed to utilise a small number of frameworks/libraries of our choice, with the restriction of the provided servers only supporting PHP ver 5.6. After a bit of research, I decided upon both the Slim framework for the backend, and the Twig templating engine for the front-end. Although I hadn't used either before, they turned out to be fantastic additions that really integrated well and made the whole process much easier.

It was also the first time I'd used the new CSS Grid spec which had just been released. After using flexbox for the best part of 2 years, I was eager to give it a try in a project to see how they complimented/differentiate from one another. Whilst developing the backend, I'd been creating a design in codepen as an experiment, ready to drop in once ready.

With that said, adding views, creating controllers, and handling user access wasn't as difficult as I initially thought it would be, and the end result considering the time constraints and the number of requirements was really pleasing.