Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 

Repository files navigation

CIS1054 Part 2 - Web Application

This repository contains the implementation files for Part 2 of the CIS1054 project, focusing on a PHP/MySQL-based web application that demonstrates practical server-side development with persistent data storage.

Academic Year: 2022-2023 (Year 1, Semester 2)

👥 Contributors

This project was developed by:


📋 Project Overview

This project extends upon Part 1 and introduces a full-featured PHP web application backed by a MySQL database. It demonstrates:

  1. Dynamic Content Rendering
  2. Database Integration using MySQL
  3. Configuration Handling via config.ini
  4. Session management and navigation
  5. Dependency management with Composer (vendor libraries)

📁 Repository Structure

.
├── CIS1054Part2
│   ├── WebProject
│   │   ├── assets
│   │   │   ├── css
│   │   │   │   ├── main.css
│   │   │   │   └── main.min.css
│   │   │   ├── images
│   │   │   │   ├── ...                 # multiple images
│   │   │   │   └── menu_imgs
│   │   │   │       └── ...             # multiple images used for menu
│   │   │   └── js
│   │   │       ├── main.js
│   │   │       └── main.min.js
│   │   ├── .htaccess
│   │   ├── config.ini
│   │   ├── index.php                   # entry point for web application
│   │   ├── ...                         # more PHP source files
│   │   ├── templates
│   │   │   ├── .htaccess
│   │   │   └── ...                     # multiple HTML files
│   │   └── vendor.zip                  # composer vendor files (Needs to be unzipped)
│   ├── web_project_cis1054.sql
│   └── web_project_cis1054_backup.sql
└── README.md

🚀 Getting Started

Prerequisites

  • XAMPP (required for Apache + MySQL)
  • PHP 7.0 or higher
  • MySQL (via XAMPP)
  • Apache Web Server (via XAMPP)
  • Composer for managing PHP dependencies
  • Web browser

Installation & Running

1. Place the `CIS1054Part2` folder in XAMPP’s `htdocs` folder  
        e.g. `C:\xampp\htdocs\CIS1054Part2`

2. Navigate into the project root (the folder containing `composer.json`, `vendor.zip`, etc.)

3. Run Composer to install dependencies:

composer install

This will create the `vendor/` directory and download any required libraries. (If `vendor.zip` is already bundled, you may use that, but Composer is preferred.)

4. (If `vendor.zip` is provided instead of a `composer.json`)  
Unzip `vendor.zip` into the project root so that a `vendor/` folder is present.

5. Start Apache and MySQL using the XAMPP Control Panel.

6. Create a MySQL database (see Database section below).

7. Import the SQL schema (see Database section).

8. Configure database credentials in `config.ini`.

9. In your browser, go to:  
http://localhost/CIS1054Part2/WebProject/index.php

🛠 Database Setup & Permissions

Importing the SQL Schema

via phpMyAdmin:

  • Log in, select your database
  • Use “Import” → upload web_project_cis1054.sql

You may also optionally use web_project_cis1054_backup.sql as a backup or example dataset.

Minimum Privileges & Credentials

Your MySQL user (as used in config.ini) should have only the necessary privileges to operate on the application tables. At minimum, grant:

  • SELECT
  • INSERT
  • UPDATE
  • DELETE

⚠️ Make sure:

  • The user and password match your MySQL credentials
  • dbname matches the name of the database you imported
  • The user has the minimal necessary privileges (as above)

📝 Notes

  • The application must be run with XAMPP’s Apache and MySQL (i.e. both must be active).
  • You must have Composer installed and run composer install to pull dependencies (or use vendor.zip)
  • Session handling and navigation are supported throughout the application.
  • The database schema must match what the application expects.
  • Use minimal permissions for the database user to reduce security risks.

📌 Academic project - CIS1054 coursework submission.

About

Codebase for the CPS1054 Group Project Part 2 - Web Application

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages