- PHP v8.1.2
- Laravel Framework v8.x
- Composer, Dependency Manager
- mySQL Database
- Eloquent, Database ORM
- HTML, Blade templates
- CSS, Bootstrap library
- JavaScript, jQuery library
- Client: A software company that provides on-line educational solutions for education establishments and training providers.
- Brief: design, build, and test a database-driven website to manage quizzes, each consisting of a set of multiple-choice questions and their associated answers.
The application is pre-configured with three user accounts for each of the user permission levels.
Login Details:
- Email:
restricted@test.com - Email:
view@test.com - Email:
edit@test.com
Password for all user accounts: password
For full guidance, refer to file 2.2. Quiz Manager Setup Instructions
-
Git clone the GitHub repository
-
Install
- PHP
- mySQL
- Composer
- Node.js and NPM
- Makefile
-
Create a
.envfile to contain sensitive credentials as environment variables (see.env.examplefile as an example)- In the root of your project, run
php artisan key:generateandphp artisan config:cacheto generate an application key for your application (APP_KEYin.envfile))
- In the root of your project, run
-
Compile CSS UI resources by running
npm install, and build dev assets runningnpm run dev, -
Set up a local mySQL database named
quiz-manager(details below) -
Run the command
make migrate-seedto run database migrations and seeders -
Run
make startto start the server. View application on your localhost.
See Makefile for a list of commands available in the application.
-
Install the mySQL client,
-
Run the mySQL client -
$ mysql -u root -proot- userp- you will be prompted to enter your mysql root user password. Please enter when you have input your password.
-
Create a local database the application can integrate with:
CREATE DATABASE quiz_manager;- Run the query
SHOW DATABASES;, to confirm your database has been created.
- Run the query
-
In the Quiz Manager
.envfile (line 9-15), please check the Database Connection config matches the details you configured locally.DB_CONNECTION,DB_HOST,DB_PORT- you should not have to update theseDB_DATABASE- update with the name of your Database (e.g.quiz_manager)DB_USERNAME,DB_PASSWORD- represent your personal mySQL user credentials
-
Once your
.envconfig is set up, runmake migrateto confirm your Database connection is working as expected.




