├── views ├── includes │ ├── styles │ │ └── style.css │ ├── footer.php │ ├── alert.php │ ├── 404.php │ └── header.php └── home.php ├── bootstrap.php ├── .htaccess ├── controllers └── HomeController.php ├── app └── classes │ ├── Redirect.php │ └── Session.php ├── .idea ├── vcs.xml ├── .gitignore ├── sqldialects.xml ├── modules.xml ├── gestionEmployees.iml ├── dataSources.xml └── php.xml ├── database └── DB.php ├── index.php └── autoload.php /views/includes/styles/style.css: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /bootstrap.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.htaccess: -------------------------------------------------------------------------------- 1 | Options All -Indexes 2 | 3 | RewriteEngine On 4 | 5 | RewriteBase /gestion/ 6 | 7 | RewriteRule ^([-a-zA-Z0-9]+)$ index.php?page=$1 -------------------------------------------------------------------------------- /controllers/HomeController.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/classes/Redirect.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/classes/Session.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | # Editor-based HTTP Client requests 5 | /httpRequests/ 6 | # Datasource local storage ignored files 7 | /dataSources/ 8 | /dataSources.local.xml 9 | -------------------------------------------------------------------------------- /.idea/sqldialects.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /views/includes/footer.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | -------------------------------------------------------------------------------- /views/home.php: -------------------------------------------------------------------------------- 1 | 2 |
3 |
4 |

Home

5 |

Bonjour !

6 |
7 |
8 | -------------------------------------------------------------------------------- /database/DB.php: -------------------------------------------------------------------------------- 1 | exec("set names utf8"); 6 | $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING); 7 | return $pdo; 8 | } 9 | } 10 | ?> 11 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/gestionEmployees.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /views/includes/alert.php: -------------------------------------------------------------------------------- 1 | '. 5 | $_COOKIE['success'].''; 6 | } 7 | 8 | if (isset($_COOKIE['danger'])){ 9 | echo '
'. 10 | $_COOKIE['danger'].'
'; 11 | } 12 | 13 | if (isset($_COOKIE['info'])){ 14 | echo '
'. 15 | $_COOKIE['info'].'
'; 16 | } 17 | 18 | ?> 19 | 20 | 21 | -------------------------------------------------------------------------------- /views/includes/404.php: -------------------------------------------------------------------------------- 1 | 2 |
3 |
4 |

404

5 |

Opps! Page not found.

6 |

7 | The page you’re looking for doesn’t exist. 8 |

9 | Go Home 10 |
11 |
12 | -------------------------------------------------------------------------------- /index.php: -------------------------------------------------------------------------------- 1 | index($page); 13 | }else{ 14 | include 'views/includes/404.php'; 15 | } 16 | }else{ 17 | $home->index('home'); 18 | } 19 | 20 | require_once './views/includes/footer.php'; 21 | 22 | ?> -------------------------------------------------------------------------------- /.idea/dataSources.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | mysql.8 6 | true 7 | com.mysql.cj.jdbc.Driver 8 | jdbc:mysql://localhost:3306 9 | $ProjectFileDir$ 10 | 11 | 12 | -------------------------------------------------------------------------------- /autoload.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.idea/php.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 9 | 10 | 12 | 13 | 15 | 16 | 18 | -------------------------------------------------------------------------------- /views/includes/header.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Gestion des Employes 9 | 10 | 11 | 13 | 14 | 15 | --------------------------------------------------------------------------------