Create a copy of this web application : Exercise Looper
Intermediate : 31.10.2022
Final : 21.12.2022
We must use HTML5 and CSS.
Frameworks and JavaScript are forbidden by default
- Have a
Php
andMariadb
service installed and be able to reach them in a shell (testphp -v
andmariadb -v
to verify. Successful verification if the command is recognized. - Have the PDO extension activated on the Php server (change
;extension=pdo_mysql
toextension=pdo_mysql
in thephp.ini
file or verify that it is already done).
-
Get the repository from GitHub (clone or
.zip
download) (example clone in a shell in theC:/Users/Alice/Documents/GitHub/
folder)VS: cd C:/Users/Alice/Documents/GitHub/ git clone https://github.com/CPNV-ES/MAW1-BPT-SMD.git
-
Open a shell and install the PHP packages (with
Composer
) in the folderapp
!cd app composer install
-
Start the MySQL service. Log in (with an SQL client for example) as the
root
account. Execute theMAW1-BPT-SMD\modelisation\createDatabase.sql
file, which will create thelooper
database and its tables. Then create a new user (named herelooper
withlooper
for password) and give him access to the previously createdlooper
database. Connect to the new user to verify that it has been created and that it has access to thelooper
database. -
Go to
app
. Duplicate the.const.php.example
file and rename it to.const.php
. -
Start an IDE at the root of the repository. Modify the values of the
.const.php
file in order to register the identifiers of connection to the database (4 values + a cartridge).$user = "looper"; $pass = "looper"; //Special php characters must be preceded by \ $dbhost = "localhost"; $dbname = "looper";
-
Start a PHP server with the command :
php -S localhost:<PORT> -t public
on a free port (here 8888). -
Open a web browser on the localhost address and the chosen port:
localhost:<PORT>
.
- Create a new blank exercise with a title
- Add a new field with a title and a value type
- Edit an existing field to either rename it or change the value type
- Destroy an existing field
- List the exercises that are ready for answers
- Take an exercise to see all the fields
- Answer the taken exercise by filling the fields
- Update the existing answers for a taken exercise
- List all the exercises in 3 columns based on their state
- Destroy an exercise (only when building or closed)
- Change state of an exercise through icon buttons
- Stats for an exercise: show the recap (all takes, all fields)
- Stats for an exercise: show the answers of all fields of one take
- Stats for an exercise: show the answers on one field of all takes