Compare commits

..

No commits in common. 'master' and 'feature/Connection' have entirely different histories.

@ -2,14 +2,11 @@
<module type="WEB_MODULE" version="4"> <module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager"> <component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$"> <content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/config" isTestSource="false" packagePrefix="config\" />
<sourceFolder url="file://$MODULE_DIR$/controleur" isTestSource="false" packagePrefix="controleur\" />
<sourceFolder url="file://$MODULE_DIR$/metier" isTestSource="false" packagePrefix="modeles\" />
<sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" /> <sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/tests" isTestSource="true" /> <sourceFolder url="file://$MODULE_DIR$/tests" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/DAL" isTestSource="false" packagePrefix="DAL\" />
<sourceFolder url="file://$MODULE_DIR$/src/config" isTestSource="false" packagePrefix="config\" />
<sourceFolder url="file://$MODULE_DIR$/src/controleur" isTestSource="false" packagePrefix="controleur\" />
<sourceFolder url="file://$MODULE_DIR$/src/metier" isTestSource="false" packagePrefix="metier\" />
<sourceFolder url="file://$MODULE_DIR$/src/model" isTestSource="false" packagePrefix="model\" />
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" packagePrefix="src\" />
<excludeFolder url="file://$MODULE_DIR$/vendor/composer" /> <excludeFolder url="file://$MODULE_DIR$/vendor/composer" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/polyfill-ctype" /> <excludeFolder url="file://$MODULE_DIR$/vendor/symfony/polyfill-ctype" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/polyfill-mbstring" /> <excludeFolder url="file://$MODULE_DIR$/vendor/symfony/polyfill-mbstring" />

@ -0,0 +1,29 @@
<?php
namespace DAL;
use PDO;
class AdminGateway
{
private $con;
/**
* @param $con
*/
public function __construct($con)
{
$this->con = $con;
}
public function login(string $login):array
{
try{
$query = 'SELECT password,mail FROM Admin WHERE name = :login;';
$this->con->executeQuery($query, array(':login' => array($login, PDO::PARAM_STR)));
return $this->con->getResults();
}catch (\PDOException $e){
throw new \Exception("PDO error");
}
}
}

@ -0,0 +1,60 @@
<?php
namespace DAL;
use Exception;
use metier\Article;
use PDO;
class ArticleGateway
{
private $con;
/**
* @param $con
*/
public function __construct($con)
{
$this->con = $con;
}
/**
* @throws Exception
*/
public function getAllArticles():array
{
try {
$query = 'SELECT * FROM Article;';
$this->con->executeQuery($query, array());
return $this->con->getResults();
}catch (\PDOException $e){
throw new Exception("PDO error");
}
}
/**
* @throws Exception
*/
public function addArticle(Article $article){
try {
$query = 'INSERT INTO Article VALUES (:id,:title,to_date(:date,"Dy, DD Mon YYYY"),:description,:guid,:link,:mediaContent,:provenance);';
$this->con->executeQuery($query, array(':id' => array($article->getId(), PDO::PARAM_STR),
':title' => array($article->getTitle(), PDO::PARAM_STR),
':date' => array($article->getDate(), PDO::PARAM_STR),
':description' => array($article->getDescription(), PDO::PARAM_STR),
':guid' => array($article->getGuid(), PDO::PARAM_STR),
':link' => array($article->getLink(), PDO::PARAM_STR),
':mediaContent' => array($article->getMediaContent(), PDO::PARAM_STR),
':provenance' => array($article->getProvenance(), PDO::PARAM_INT)));
}catch (\PDOException $e){
throw new Exception("PDO error");
}
}
public function removeAllArticleForParser(){
try{
$query = 'DELETE FROM Article;';
$this->con->executeQuery($query);
}catch(\PDOException $p){
throw new Exception("Data is not delete.");
}
}
}

@ -42,17 +42,10 @@ class Connection extends PDO
foreach ($parameters as $name => $value) { foreach ($parameters as $name => $value) {
$this->stmt->bindValue($name, $value[0], $value[1]); $this->stmt->bindValue($name, $value[0], $value[1]);
} }
if($this->stmt->execute()){
return true;
} else {
$error = $this->stmt->errorInfo();
throw new Exception("PDO error: ".$error[2]);
}
return $this->stmt->execute();
}catch (\PDOException $e){ }catch (\PDOException $e){
throw new Exception("PDO error: ".$e->getMessage()); throw new Exception("PDO error");
}catch (\Error $r){
throw new Error("executionQuery not possible : ".$r->getMessage());
} }
} }

@ -0,0 +1,57 @@
<?php
namespace DAL;
use metier\Flux;
use PDO;
class FluxGateway
{
private Connection $con;
public function __construct(Connection $con){
$this->con = $con;
}
public function addFlux($flux){
try{
$query = 'INSERT INTO Flux VALUES (:flux);';
$this->con->executeQuery($query, array(':flux' => array($flux->getFlux(), PDO::PARAM_STR)));
}catch (\PDOException $e){
throw new \Exception("PDO error");
}
}
public function removeFlux($flux){
try{
$query = 'DELETE FROM Flux WHERE flux = :flux;';
$this->con->executeQuery($query, array(':flux' => array($flux->getFlux(), PDO::PARAM_STR)));
}catch (\PDOException $e){
throw new \Exception("PDO error");
}
}
public function findAllFlux(){
try{
$query = 'SELECT * FROM Flux;';
$this->con->executeQuery($query);
return $this->con->getResults();
}catch (\PDOException $e){
throw new \Exception("PDO error");
}
}
public function findFlux(Flux $flux){
return $this->findFluxBySrc($flux->getFlux());
}
public function findFluxBySrc(string $flux){
try{
$query = 'SELECT * FROM Flux WHERE flux = :flux;';
$this->con->executeQuery($query, array(':flux' => array($flux, PDO::PARAM_STR)));
return $this->con->getResults();
}catch (\PDOException $e){
throw new \Exception("PDO error");
}
}
}

@ -6,12 +6,11 @@
}, },
"autoload": { "autoload": {
"psr-4": { "psr-4": {
"src\\": "src/", "controleur\\": "controleur/",
"controleur\\": "src/controleur/", "config\\": "config/",
"config\\": "src/config/", "model\\": "model/",
"model\\": "src/model/", "DAL\\": "DAL/",
"DAL\\": "src/DAL/", "metier\\": "metier/"
"metier\\": "src/metier/"
} }
} }
} }

@ -1,8 +1,6 @@
<?php <?php
namespace config; namespace config;
use http\Exception\InvalidArgumentException;
class Validation class Validation
{ {
public static function val_action($action) public static function val_action($action)
@ -10,7 +8,7 @@ class Validation
if (!isset($action)) { if (!isset($action)) {
throw new \Exception('pas d\'action'); throw new \Exception('pas d\'action');
//on pourrait aussi utiliser //on pourrait aussi utiliser
$action = $_GET['action'] ?? ''; //$action = $_GET['action'] ?? 'no';
// This is equivalent to: // This is equivalent to:
//$action = if (isset($_GET['action'])) $action=$_GET['action'] else $action='no'; //$action = if (isset($_GET['action'])) $action=$_GET['action'] else $action='no';
} }
@ -33,27 +31,4 @@ class Validation
$age = 0; $age = 0;
} }
} }
public static function validationLogin(string &$username)
{
$username = trim($username);
if (!isset($username) || !filter_var($username, FILTER_SANITIZE_STRING) || !filter_var($username, FILTER_FLAG_EMPTY_STRING_NULL)){
return false;
}
return true;
}
public static function validationMdp(string &$mdp)
{
$mdp = trim($mdp);
if (!isset($mdp) || !filter_var($mdp, FILTER_SANITIZE_STRING) || !filter_var($mdp, FILTER_FLAG_EMPTY_STRING_NULL)){
return false;
}
return true;
}
public static function ValidationFlux(string &$flux)
{
if (!isset($flux) || !filter_var($flux, FILTER_SANITIZE_URL) || !filter_var($flux, FILTER_VALIDATE_URL)){
return false;
}
return true;
}
} }

@ -1,7 +1,7 @@
<?php <?php
//gen //gen
$rep = __DIR__ . '/fluxRSS/'; $rep = __DIR__ . '/../';
// liste des modules à inclure // liste des modules à inclure
@ -9,8 +9,7 @@ $rep = __DIR__ . '/fluxRSS/';
//BD //BD
$base = 'mysql:host=londres.uca.local;dbname=dbrorossetto'; $base = 'dbrorossetto';
$login = 'rorossetto'; $login = 'rorossetto';
$mdpBd = 'tpphp'; $mdp = 'tpphp';
$path = '~mapoint2/public_html/SAE/Php_RSS'; $path = '~mapoint2/public_html/SAE/Php_RSS';
$nbArticle = 10;

@ -2,20 +2,12 @@
namespace controleur; namespace controleur;
use config\Validation;
use DAL\ArticleGateway;
use DAL\Connection;
use DAL\FluxGateway;
use http\Exception;
use http\Url;
use metier\Flux;
use model\AdminModel; use model\AdminModel;
use model\ArticleModel; use model\ArticleModel;
use model\FluxModel;
class AdminControleur class AdminControleur
{ {
public function init(){ public function __construct(){
global $twig; // nécessaire pour utiliser variables globales global $twig; // nécessaire pour utiliser variables globales
//debut //debut
@ -35,27 +27,10 @@ class AdminControleur
case 'connection': case 'connection':
$this->connection();; $this->connection();;
break; break;
case 'deleteFlux':
$this->deleteFlux();;
break;
case 'validationFormulaire': case 'validationFormulaire':
$this->ValidationFormulaire($dVueEreur); $this->ValidationFormulaire($dVueEreur);
break; break;
case 'listFlux':
$this->listFlux();
break;
case 'ajoutFlux':
$this->ajoutFlux();
break;
case 'changeNbArticle':
$this->changeNbArticle();
break;
//mauvaise action //mauvaise action
default: default:
$dVueEreur[] = "Erreur d'appel php"; $dVueEreur[] = "Erreur d'appel php";
@ -79,12 +54,9 @@ class AdminControleur
{ {
global $twig; global $twig;
$articleModel = new ArticleModel(); $articleModel = new ArticleModel();
$nbArticle = isset($_SESSION['nbArticleAdmin']) ? intval($_SESSION['nbArticleAdmin']) : 5;
$allArticles = $articleModel->getArticles();
$articles = array_slice($allArticles, 0, $nbArticle);
if (AdminModel::isAdmin()) { if (AdminModel::isAdmin()) {
$dVue = [ $dVue = [
'data' => $articles 'data' => $articleModel->getArticles()
]; ];
echo $twig->render('listArticleAdmin.html', [ echo $twig->render('listArticleAdmin.html', [
'dVue' => $dVue, 'dVue' => $dVue,
@ -96,29 +68,11 @@ class AdminControleur
} }
} }
public function listFlux(){
global $twig;
$fluxModel = new FluxModel();
if (AdminModel::isAdmin()) {
$dVue = [
'data' => $fluxModel->findAllFlux()
];
echo $twig->render('listFlux.html', [
'dVue' => $dVue,
'isAdmin' => AdminModel::isAdmin()
]);
}
else {
$this->connection();
}
}
public function connection(){ public function connection(){
global $twig; // nécessaire pour utiliser variables globales global $twig; // nécessaire pour utiliser variables globales
$renderTemplate = true; $renderTemplate = true;
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['username'])){ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['username'])){
$_REQUEST['action'] = null;
$this->login(); $this->login();
$renderTemplate = false; $renderTemplate = false;
} }
@ -127,37 +81,6 @@ class AdminControleur
} }
} }
public function deleteFlux(){
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['flux'])){
$articleModel = new ArticleModel();
$fluxModel = new FluxModel();
$articleModel->removeArticleIdFlux(intval($_POST['flux']));
$fluxModel->removeFluxById(intval($_POST['flux']));
$_REQUEST['action'] = 'listFlux';
$this->init();
}
else{
$_REQUEST['action'] = 'listFlux';
$this->init();
}
}
public function ajoutFlux(){
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['fluxAdd'])){
$fluxModel = new FluxModel();
if(Validation::ValidationFlux($_POST['fluxAdd'])){
$fluxModel->addFluxBySrc($_POST['fluxAdd']);
}
$_REQUEST['action'] = 'listFlux';
unset($_POST['fluxAdd']);
$this->init();
}
else{
$_REQUEST['action'] = 'listFlux';
$this->init();
}
}
public function login(){ public function login(){
$username = $_POST['username']; $username = $_POST['username'];
$password = $_POST['password']; $password = $_POST['password'];
@ -165,7 +88,7 @@ class AdminControleur
$adminModel = new AdminModel(); $adminModel = new AdminModel();
$admin = $adminModel->connection($username, $password); $admin = $adminModel->connection($username, $password);
if($admin != null) { if($admin != null) {
$this->init(); $this->listArticle();
} }
else{ else{
unset($_POST['username']); unset($_POST['username']);
@ -173,13 +96,4 @@ class AdminControleur
$this->connection(); $this->connection();
} }
} }
public function changeNbArticle()
{
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['nbArticleAdmin'])) {
$_SESSION['nbArticleAdmin'] = $_POST['nbArticleAdmin'];
unset($_POST['action']);
}
$this->init();
}
} }

@ -11,15 +11,11 @@ require 'AltoRouter.php';
class FrontControleur class FrontControleur
{ {
public function __construct(){ public function __construct(){
$routeur = new AltoRouter();
global $twig; global $twig;
$router = new AltoRouter(); $router = new AltoRouter();
$router->setBasePath('~rorossetto/Php_RSS/fluxRSS/'); $router->setBasePath('~mapoint2/SAE/Php_RSS/fluxRSS/');
$router->map('GET', '/', 'UserControleur'); $router->map('GET', '/', 'UserControleur');
$router->map('GET|POST', '/[a:action]?', 'UserControleur');
$router->map('GET|POST','/user/[a:action]?','UserControleur'); $router->map('GET|POST','/user/[a:action]?','UserControleur');
$router->map('GET|POST','/admin/[a:action]?','AdminControleur'); $router->map('GET|POST','/admin/[a:action]?','AdminControleur');
@ -31,7 +27,7 @@ class FrontControleur
else { else {
session_start(); session_start();
$controller=$match['target'] ?? null; $controller=$match['target'] ?? null;
$action=$match['params']['action'] ?? "init"; $action=$match['params']['action'] ?? null;
try { try {
if($controller == "AdminControleur"){ if($controller == "AdminControleur"){
if (!AdminModel::isAdmin()){ if (!AdminModel::isAdmin()){
@ -54,6 +50,4 @@ class FrontControleur
} }
} }
} }
} }

@ -3,10 +3,11 @@ namespace controleur;
use model\AdminModel; use model\AdminModel;
use model\ArticleModel; use model\ArticleModel;
use model\Parser;
class UserControleur class UserControleur
{ {
public function init() public function __construct()
{ {
global $twig; // nécessaire pour utiliser variables globales global $twig; // nécessaire pour utiliser variables globales
//debut //debut
@ -35,10 +36,6 @@ class UserControleur
$this->ValidationFormulaire($dVueEreur); $this->ValidationFormulaire($dVueEreur);
break; break;
case 'changeNbArticle':
$this->changeNbArticle();
break;
//mauvaise action //mauvaise action
default: default:
$dVueEreur[] = "Erreur d'appel php"; $dVueEreur[] = "Erreur d'appel php";
@ -62,11 +59,8 @@ class UserControleur
{ {
global $twig; global $twig;
$articleModel = new ArticleModel(); $articleModel = new ArticleModel();
$nbArticle = isset($_SESSION['nbArticle']) ? intval($_SESSION['nbArticle']) : 5;
$allArticles = $articleModel->getArticles();
$articles = array_slice($allArticles, 0, $nbArticle);
$dVue = [ $dVue = [
'data' => $articles 'data' => $articleModel->getArticles()
]; ];
echo $twig->render('listArticle.html', [ echo $twig->render('listArticle.html', [
'dVue' => $dVue, 'dVue' => $dVue,
@ -74,15 +68,6 @@ class UserControleur
]); ]);
} }
public function changeNbArticle()
{
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['nbArticle'])) {
$_SESSION['nbArticle'] = $_POST['nbArticle'];
unset($_POST['action']);
}
$this->init();
}
/** /**
* @throws \Twig\Error\RuntimeError * @throws \Twig\Error\RuntimeError
* @throws \Twig\Error\SyntaxError * @throws \Twig\Error\SyntaxError

@ -1,7 +1,7 @@
<?php <?php
//chargement config //chargement config
require_once __DIR__ . '/src/config/config.php'; require_once __DIR__ . '/config/config.php';
require __DIR__ . '/vendor/autoload.php'; require __DIR__ . '/vendor/autoload.php';

@ -2,38 +2,28 @@
namespace metier; namespace metier;
use DateTime;
class Article class Article
{ {
private int $id; private string $id;
private string $title; private string $title;
private string $date; private string $date;
private string $description; private string $description;
private string $guid; private string $guid;
private string $link; private string $link;
private string $mediaContent; private string $mediaContent;
private int $provenance; private string $provenance;
/** /**
* @param int $id * @param string $id
* @param string $title * @param string $title
* @param string $date * @param string $date
* @param string $description * @param string $description
* @param string $guid * @param string $guid
* @param string $link * @param string $link
* @param string $mediaContent * @param string $mediaContent
* @param int $provenance * @param string $provenance
*/ */
public function __construct( public function __construct(string $id, string $title, string $date, string $description, string $guid, string $link, string $mediaContent, string $provenance)
?int $id,
string $title,
string $date,
string $description,
string $guid,
string $link,
string $mediaContent,
int $provenance)
{ {
$this->id = $id; $this->id = $id;
$this->title = $title; $this->title = $title;
@ -130,8 +120,4 @@ class Article
return $this->title . $this->date . $this->description; return $this->title . $this->date . $this->description;
} }
public function dateStr(): string{
$dateTime = new DateTime($this->date);
return $dateTime->format('d/m/y à H:i') . '';
}
} }

@ -4,13 +4,9 @@ namespace metier;
class Flux class Flux
{ {
private ?int $id; private string $id;
private string $flux; private string $flux;
public function __construct(?int $id, string $flux){
$this->id =$id;
$this->flux = $flux;
}
/** /**
* @return string * @return string
*/ */
@ -28,14 +24,9 @@ class Flux
} }
/** /**
* @return int * @return string
*/ */
public function getId(): int public function getId(): string
{
return $this->id;
}
public function __toString(): string
{ {
return $this->id; return $this->id;
} }

@ -0,0 +1,43 @@
<?php
namespace model;
use DAL\AdminGateway;
use DAL\Connection;
use metier\Admin;
class AdminModel
{
/**
* @throws \Exception
*/
public function connection (string $username, string $mdp){
//Validation::validationLogin($username);
//Validation::validationMdp($mdp);
$gwArticle = new AdminGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$lmdp = $gwArticle->login($username);
foreach ($lmdp as $motDePasse){
if (true){//password_verify($mdp,$motDePasse['password']) or $mdp == $motDePasse['password']){
$_SESSION['role'] = 'admin';
$_SESSION['pseudo'] = $username;
return new Admin($username,$motDePasse['mail']);
}
}
return null;
}
public static function isAdmin(): bool
{
return (isset($_SESSION['role']) && $_SESSION['role'] == 'admin');
}
public static function deconnection(){
$_SESSION['role'] = "";
unset($_SESSION['role']);
$_SESSION['pseudo'] = "";
unset($_SESSION['pseudo']);
header("Location: /~mapoint2/SAE/Php_RSS/fluxRSS/admin");
}
}

@ -0,0 +1,24 @@
<?php
namespace model;
use DAL\{ArticleGateway, Connection};
use Exception;
use metier\Article;
class ArticleModel
{
/**
* @throws Exception
*/
public static function getArticles() : array
{
$gwArticle = new ArticleGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$tabArticle = array();
$res = $gwArticle->getAllArticles();
foreach($res as $row){
$tabArticle[] = new Article($row['id'], $row['title'],$row['datePub'],$row['description'],$row['guid'],$row['link'],$row['mediaContent'],$row['provenance'] );
}
return $tabArticle;
}
}

@ -0,0 +1,71 @@
<?php
namespace model;
use DAL\Connection;
use DAL\FluxGateway;
use metier\Flux;
require_once "config/config.php";
class FluxModel
{
public function FindAllFlux(){
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$data = array();
$result = $gateway->findAllFlux();
foreach ($result as $row){
$data[] = new Flux($row['$flux']);
}
return $data;
}
public function addFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$data = $this->findFlux($flux);
if ($data == array()) {
$gateway->addFlux($flux);
}
}
public function addFluxBySrc(string $flux): Flux {
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$newFlux = new Flux($flux);
$gateway->addFlux($newFlux);
return $newFlux;
}
public function removeFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$gateway->removeFlux($flux);
}
public function removeFluxBySrc(string $flux): Flux {
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$newFlux = new Flux($flux);
$gateway->removeFlux($newFlux);
return $newFlux;
}
public function findFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$data = array();
$result = $gateway->findFlux($flux);
foreach ($result as $row){
$data[] = new Flux($row['$flux']);
}
return $data;
}
public function findFluxBySrc(string $flux){
$gateway = new FluxGateway(new Connection('mysql:host= londres.uca.local ; dbname= dbrorossetto', 'rorossetto', 'tpphp'));
$data = array();
$result = $gateway->findFluxBySrc($flux);
foreach ($result as $row){
$data[] = new Flux($row['$flux']);
}
return $data;
}
}

@ -0,0 +1,84 @@
<?php
namespace model;
use DAL\ArticleGateway;
use DAL\Connection;
use DAL\FluxGateway;
use DOMDocument;
use Exception;
use metier\Article;
use metier\Flux;
class Parser
{
private FluxGateway $fluxGateway;
private ArticleGateway $articleGateway;
public function __construct(FluxGateway $fluxGateway, ArticleGateway $articleGateway){
$this->fluxGateway = $fluxGateway;
$this->articleGateway = $articleGateway;
}
public function parseArticles(Flux $flux): array
{
$dom = new DOMDocument();
$tabArticle = array();
if ($dom->load($flux->getFlux())){
$items = $dom->getElementsByTagName('item');
foreach ($items as $item) {
$title = $item->getElementsByTagName('title')[0]->nodeValue;
$date = $item->getElementsByTagName('pubDate')[0]->nodeValue;
$guid = $item->getElementsByTagName('guid')[0]->nodeValue;
$link = $item->getElementsByTagName('link')[0]->nodeValue;
$description = $item->getElementsByTagName('description')[0]->nodeValue;
$media = $item->getElementsByTagName('media:content');
$mediaUrl = null;
if ($media->length > 0){
$mediaUrl = $media->item(0)->getAttribute('url');
}
$tabArticle[] = new Article((int)null, $title, $date, $description, $guid, $link, $mediaUrl, $flux->getId());
}
return $tabArticle;
} else {
// En cas d'erreur lors du chargement du flux RSS, lever une exception
throw new Exception("Erreur lors du chargement du flux RSS");
}
}
/**
* @throws Exception
*/
public function parseAll($fluxes){
foreach ($fluxes as $flux){
$tabArticles[] =$this->parseArticles($flux);
}
return $tabArticles;
}
/**
* @throws Exception
*/
public function addAllArticles()
{
$this->articleGateway->removeAllArticleForParser();
$allFlux = $this->fluxGateway->findAllFlux();
$allArticles = $this->parseAll($allFlux);
foreach ($allArticles as $article) {
$this->articleGateway->addArticle($article);
}
return $allArticles;
}
}
$gwArt = new ArticleGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$gwFl = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$pars = new Parser( $gwFl,$gwArt);

@ -1,25 +0,0 @@
<?php
namespace DAL;
use PDO;
class AdminGateway
{
private $con;
/**
* @param $con
*/
public function __construct($con)
{
$this->con = $con;
}
public function login(string $login):array
{
$query = 'SELECT password,mail FROM Admin WHERE name = :login;';
$this->con->executeQuery($query, array(':login' => array($login, PDO::PARAM_STR)));
return $this->con->getResults();
}
}

@ -1,64 +0,0 @@
<?php
namespace DAL;
use Exception;
use metier\Article;
use metier\Flux;
use PDO;
class ArticleGateway
{
private $con;
/**
* @param $con
*/
public function __construct($con)
{
$this->con = $con;
}
/**
* @throws Exception
*/
public function getAllArticles():array
{
$query = 'SELECT * FROM Article ORDER BY datePub DESC;';
$this->con->executeQuery($query, array());
return $this->con->getResults();
}
/**
* @throws Exception
*/
public function addArticle(Article $article){
$query = "INSERT INTO Article VALUES (:id,:title,STR_TO_DATE(:datePub, '%d/%m/%y %H:%i'),:description,:guid,:link,:mediaContent,:provenance);";
$this->con->executeQuery($query, array(':id' => array($article->getId(), PDO::PARAM_STR),
':title' => array($article->getTitle(), PDO::PARAM_STR),
':datePub' => array($article->getDate(), PDO::PARAM_STR),
':description' => array($article->getDescription(), PDO::PARAM_STR),
':guid' => array($article->getGuid(), PDO::PARAM_STR),
':link' => array($article->getLink(), PDO::PARAM_STR),
':mediaContent' => array($article->getMediaContent(), PDO::PARAM_STR),
':provenance' => array($article->getProvenance(), PDO::PARAM_INT)));
}
public function removeAllArticleForParser(){
$query = 'DELETE FROM Article;';
$this->con->executeQuery($query);
}
public function removeAllArticleFromFlux(int $idFlux){
try {
$query = 'DELETE FROM Article WHERE Provenance = :idFlux;';
$this->con->executeQuery($query, array(':idFlux' => array($idFlux, PDO::PARAM_INT)));
}catch(\PDOException $p){
throw new Exception("Data of flux is not delete.");
}
}
public function findArticleByFlux(int $flux){
$query = 'SELECT * FROM Article WHERE provenance = :flux;';
$this->con->executeQuery($query, array(':flux' => array($flux, PDO::PARAM_INT)));
return $this->con->getResults();
}
}

@ -1,56 +0,0 @@
<?php
namespace DAL;
use metier\Flux;
use PDO;
class FluxGateway
{
private Connection $con;
public function __construct(Connection $con){
$this->con = $con;
}
public function addFlux(Flux $flux)
{
$this->addFluxBySrc($flux->getFlux());
}
public function addFluxBySrc(string $flux)
{
$query = 'INSERT INTO Flux VALUES (null,:flux);';
$this->con->executeQuery($query, array(':flux' => array($flux, PDO::PARAM_STR)));
}
public function removeFlux(Flux $flux){
$this->removeFluxBySrc($flux->getFlux());
}
public function removeFluxBySrc(string $flux){
$query = 'DELETE FROM Flux WHERE flux = :flux;';
$this->con->executeQuery($query, array(':flux' => array($flux, PDO::PARAM_STR)));
}
public function removeFluxById(int $id){
$query = 'DELETE FROM Flux WHERE id = :id;';
$this->con->executeQuery($query, array(':id' => array($id, PDO::PARAM_INT)));
}
public function findAllFlux(){
$query = 'SELECT * FROM Flux;';
$this->con->executeQuery($query);
return $this->con->getResults();
}
public function findFlux(Flux $flux){
return $this->findFluxBySrc($flux->getFlux());
}
public function findFluxBySrc(string $flux){
$query = 'SELECT * FROM Flux WHERE flux = :flux;';
$this->con->executeQuery($query, array(':flux' => array($flux, PDO::PARAM_STR)));
return $this->con->getResults();
}
}

@ -1,86 +0,0 @@
<?php
namespace controleur;
use model\ArticleModel;
class erControleur
{
public function __construct()
{
global $twig; // nécessaire pour utiliser variables globales
session_start();
//debut
//on initialise un tableau d'erreur
$dVueEreur = [];
try {
$action = $_REQUEST['action'] ?? null;
switch($action) {
//pas d'action, on réinitialise 1er appel
case null:
$this->Reinit();
break;
case 'validationFormulaire':
$this->ValidationFormulaire($dVueEreur);
break;
//mauvaise action
default:
$tabArticle[] = ArticleModel::getArticles();
$dVueEreur[] = "Erreur d'appel php";
$dataview = ['Article'=> $tabArticle];
echo $twig->render('listArticle.html', ['tabArticle' => $dataview, 'dVueErreur'=>$dVueEreur]);
break;
}
} catch (\PDOException $e) {
//si erreur BD, pas le cas ici
$dVueEreur[] = 'Erreur PDO : ' . $e->getMessage();
echo $twig->render('erreur.html', ['dVueEreur' => $dVueEreur]);
} catch (\Exception $e2) {
$dVueEreur[] = 'Erreur : ' . $e2->getMessage();
echo $twig->render('erreur.html', ['dVueEreur' => $dVueEreur]);
}
//fin
exit(0);
}//fin constructeur
public function Reinit()
{
global $twig; // nécessaire pour utiliser variables globales
$dVue = [
'nom' => '',
'age' => 0,
'data' => ArticleModel::getArticles()
];
echo $twig->render('listArticle.html', [
'dVue' => $dVue
]);
}
public function ValidationFormulaire(array $dVueEreur)
{
global $twig; // nécessaire pour utiliser variables globales
//si exception, ca remonte !!!
$nom = $_POST['txtNom']; // txtNom = nom du champ texte dans le formulaire
$age = $_POST['txtAge'];
\config\Validation::val_form($nom, $age, $dVueEreur);
/*
$model = new \metier\Simplemodel();
$data = $model->get_data();
*/
$dVue = [
'nom' => $nom,
'age' => $age,
//'data' => $data,
];
echo $twig->render('Connection.html', ['dVue' => $dVue, 'dVueEreur' => $dVueEreur]);
}
}//fin class

@ -1,46 +0,0 @@
<?php
namespace model;
use config\Validation;
use DAL\AdminGateway;
use DAL\Connection;
use metier\Admin;
class AdminModel
{
/**
* @throws \Exception
*/
public function connection (string $username, string $mdp){
$gwArticle = new AdminGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
if (Validation::validationLogin($username)){
$lmdp = $gwArticle->login($username);
}
if(Validation::validationMdp($mdp)){
foreach ($lmdp as $motDePasse){
if (password_verify($mdp,$motDePasse['password']) or $mdp == $motDePasse['password']){ //Si ajout d'admin on créer avec password_hash(string $mdp)
$_SESSION['role'] = 'admin';
$_SESSION['pseudo'] = $username;
return new Admin($username,$motDePasse['mail']);
}
}
}
return null;
}
public static function isAdmin(): bool
{
return (isset($_SESSION['role']) && $_SESSION['role'] == 'admin');
}
public static function deconnection(){
$_SESSION['role'] = "";
unset($_SESSION['role']);
$_SESSION['pseudo'] = "";
unset($_SESSION['pseudo']);
header("Location: /~rorossetto/Php_RSS/fluxRSS/admin/");
}
}

@ -1,75 +0,0 @@
<?php
namespace model;
use DAL\{ArticleGateway, Connection, FluxGateway};
use Exception;
use metier\Article;
use metier\Flux;
class ArticleModel
{
/**
* @throws Exception
*/
public static function getArticles() : array
{
$gwArticle = new ArticleGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$tabArticle = array();
$res = $gwArticle->getAllArticles();
foreach($res as $row){
$tabArticle[] = new Article($row['id'], $row['title'],$row['datePub'],$row['description'],$row['guid'],$row['link'],$row['mediaContent'],$row['provenance'] );
}
return $tabArticle;
}
/**
* @throws Exception
*/
public function findArticleByFlux(Flux $flux){
$con = new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp');
$gwArticle = new ArticleGateway($con);
$dicoFluxArticle = array();
$tabArticle = array();
$res = $gwArticle->findArticleByFlux($flux->getId());
foreach ($res as $row){
$tabArticle[] = new Article($row['id'], $row['title'],$row['datePub'],$row['description'],$row['guid'],$row['link'],$row['mediaContent'],$row['provenance'] );
}
$dicoFluxArticle[] = [$flux,$tabArticle];
return $dicoFluxArticle;
}
public function findAllArticleByAllFlux(){
$con = new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp');
$gwFlux = new FluxGateway($con);
$tabFluxArticle = array();
$res = $gwFlux->findAllFlux();
foreach ($res as $row) {
$flux = new Flux((int)($row['id']),$row['flux']);
$tabFluxArticle[] = $this->findArticleByFluxAsStr($flux);
}
return $tabFluxArticle;
}
public function findArticleByFluxAsStr(Flux $flux){
$con = new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp');
$gwArticle = new ArticleGateway($con);
$tabArticle = array();
$res = $gwArticle->findArticleByFlux($flux->getId());
foreach ($res as $row){
$article = new Article($row['id'], $row['title'],$row['datePub'],$row['description'],$row['guid'],$row['link'],$row['mediaContent'],$row['provenance'] );
$tabArticle[] = (string)$article;
}
$dicoFluxArticle = [$flux,$tabArticle];
return $dicoFluxArticle;
}
public static function removeArticleIdFlux(int $idFlux)
{
$gwArticle = new ArticleGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$gwArticle->removeAllArticleFromFlux($idFlux);
}
}

@ -1,73 +0,0 @@
<?php
namespace model;
use DAL\Connection;
use DAL\FluxGateway;
use metier\Flux;
class FluxModel
{
public function findAllFlux(){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$data = array();
$result = $gateway->findAllFlux();
foreach ($result as $row){
$data[] = new Flux((int)$row['id'],$row['flux']);
}
return $data;
}
public function addFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$data = $this->findFlux($flux);
if ($data == array()) {
$gateway->addFlux($flux);
}
}
public function addFluxBySrc(string $flux): Flux {
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$newFlux = new Flux(null,$flux);
$gateway->addFlux($newFlux);
return $newFlux;
}
public function removeFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$gateway->removeFlux($flux);
}
public function removeFluxById(int $id){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$gateway->removeFluxById($id);
}
public function removeFluxBySrc(string $flux) {
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$gateway->removeFluxBySrc($flux);
}
public function findFlux(Flux $flux){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$data = array();
$result = $gateway->findFlux($flux);
foreach ($result as $row){
$data[] = new Flux((int)$row['id'],$row['$flux']);
}
return $data;
}
public function findFluxBySrc(string $flux){
$gateway = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto','rorossetto','tpphp'));
$data = array();
$result = $gateway->findFluxBySrc($flux);
foreach ($result as $row){
$data[] = new Flux((int)$row['id'],$row['$flux']);
}
return $data;
}
}

@ -1,116 +0,0 @@
<?php
namespace model;
use DAL\ArticleGateway;
use DAL\Connection;
use DAL\FluxGateway;
use DateTime;
use DOMDocument;
use Exception;
use metier\Article;
use metier\Flux;
use Twig\Error\Error;
class Parser
{
private FluxGateway $fluxGateway;
private ArticleGateway $articleGateway;
public function __construct(FluxGateway $fluxGateway, ArticleGateway $articleGateway){
$this->fluxGateway = $fluxGateway;
$this->articleGateway = $articleGateway;
}
public function parseArticles(Flux $flux): array
{
$dom = new DOMDocument();
$tabArticle = array();
try {
if ($dom->load($flux->getFlux())) {
var_dump($flux);
$items = $dom->getElementsByTagName('item');
foreach ($items as $item) {
$title = $item->getElementsByTagName('title')[0]->nodeValue;
$date = $item->getElementsByTagName('pubDate')[0]->nodeValue;
$guid = $item->getElementsByTagName('guid')[0]->nodeValue;
$link = $item->getElementsByTagName('link')[0]->nodeValue;
$description = $item->getElementsByTagName('description')[0]->nodeValue;
$mediaUrl = null;
$mediaElements = $item->getElementsByTagNameNS('http://search.yahoo.com/mrss/', 'content');
// Vérifier si un élément media:content existe
if ($mediaElements->length > 0) {
$media = $mediaElements->item(0);
$mediaUrl = $media->getAttribute('url');
}
var_dump($mediaUrl);
$dateTime = new DateTime($date);
$tabArticle[] = new Article(
(int)null,
$title,
$dateTime->format('d/m/y H:i') . '',
$description,
$guid,
$link,
($mediaUrl !== null) ? (string)$mediaUrl : '',
$flux->getId());
}
return $tabArticle;
} else {
// En cas d'erreur lors du chargement du flux RSS, lever une exception
throw new Exception("Erreur lors du chargement du flux RSS");
}
}catch (Error $e){
echo $e->getMessage();
return $tabArticle;
}catch (Exception $e2){
echo $e2->getMessage();
return $tabArticle;
}
}
/**
* @throws Exception
*/
public function parseAll($fluxes){
$tabArticles = [];
foreach ($fluxes as $flux){
$fluxx = new Flux($flux[0],$flux[1]);
$tabArticles[] = $this->parseArticles($fluxx);
}
return $tabArticles;
}
/**
* @throws Exception
*/
public function addAllArticles()
{
$tabFluxes = [];
$this->articleGateway->removeAllArticleForParser();
$allItemFlux = $this->fluxGateway->findAllFlux();
foreach ($allItemFlux as $ItemFlux){
$tabFluxes[] = new Flux(intval($ItemFlux['id']), $ItemFlux['flux']);
}
foreach ($tabFluxes as $flux) {
$tabArticle = $this->parseArticles($flux);
foreach ($tabArticle as $item) {
$this->articleGateway->addArticle($item);
}
}
}
}

@ -1,34 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="refresh" content="5">
<title>Server</title>
<script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>
</head>
<body>
<div id="testContent">
</div>
<script>
// Fonction pour charger dynamiquement le contenu de test.php
function loadTestContent() {
$.ajax({
url: 'test.php', // Chemin vers test.php
type: 'GET',
success: function(response) {
$('#testContent').html(response); // Mettre à jour le contenu
},
error: function() {
console.error('Erreur lors du chargement de test.php');
}
});
}
// Appeler la fonction pour charger le contenu au chargement initial
loadTestContent();
// Actualiser la page toutes les 5 secondes
setInterval(loadTestContent, 5000);
</script>
</body>
</html>

@ -1,14 +0,0 @@
<?php
namespace test;
use DAL\ArticleGateway;
use DAL\Connection;
use DAL\FluxGateway;
use model\Parser;
require '../../vendor/autoload.php';
$gwArt = new ArticleGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$gwFl = new FluxGateway(new Connection('mysql:host=londres.uca.local;dbname=dbrorossetto', 'rorossetto', 'tpphp'));
$pars = new Parser( $gwFl,$gwArt);
$pars->addAllArticles();
var_dump($pars);

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1,597 +0,0 @@
/*!
* Bootstrap Reboot v5.3.2 (https://getbootstrap.com/)
* Copyright 2011-2023 The Bootstrap Authors
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
:root,
[data-bs-theme=light] {
--bs-blue: #0d6efd;
--bs-indigo: #6610f2;
--bs-purple: #6f42c1;
--bs-pink: #d63384;
--bs-red: #dc3545;
--bs-orange: #fd7e14;
--bs-yellow: #ffc107;
--bs-green: #198754;
--bs-teal: #20c997;
--bs-cyan: #0dcaf0;
--bs-black: #000;
--bs-white: #fff;
--bs-gray: #6c757d;
--bs-gray-dark: #343a40;
--bs-gray-100: #f8f9fa;
--bs-gray-200: #e9ecef;
--bs-gray-300: #dee2e6;
--bs-gray-400: #ced4da;
--bs-gray-500: #adb5bd;
--bs-gray-600: #6c757d;
--bs-gray-700: #495057;
--bs-gray-800: #343a40;
--bs-gray-900: #212529;
--bs-primary: #0d6efd;
--bs-secondary: #6c757d;
--bs-success: #198754;
--bs-info: #0dcaf0;
--bs-warning: #ffc107;
--bs-danger: #dc3545;
--bs-light: #f8f9fa;
--bs-dark: #212529;
--bs-primary-rgb: 13, 110, 253;
--bs-secondary-rgb: 108, 117, 125;
--bs-success-rgb: 25, 135, 84;
--bs-info-rgb: 13, 202, 240;
--bs-warning-rgb: 255, 193, 7;
--bs-danger-rgb: 220, 53, 69;
--bs-light-rgb: 248, 249, 250;
--bs-dark-rgb: 33, 37, 41;
--bs-primary-text-emphasis: #052c65;
--bs-secondary-text-emphasis: #2b2f32;
--bs-success-text-emphasis: #0a3622;
--bs-info-text-emphasis: #055160;
--bs-warning-text-emphasis: #664d03;
--bs-danger-text-emphasis: #58151c;
--bs-light-text-emphasis: #495057;
--bs-dark-text-emphasis: #495057;
--bs-primary-bg-subtle: #cfe2ff;
--bs-secondary-bg-subtle: #e2e3e5;
--bs-success-bg-subtle: #d1e7dd;
--bs-info-bg-subtle: #cff4fc;
--bs-warning-bg-subtle: #fff3cd;
--bs-danger-bg-subtle: #f8d7da;
--bs-light-bg-subtle: #fcfcfd;
--bs-dark-bg-subtle: #ced4da;
--bs-primary-border-subtle: #9ec5fe;
--bs-secondary-border-subtle: #c4c8cb;
--bs-success-border-subtle: #a3cfbb;
--bs-info-border-subtle: #9eeaf9;
--bs-warning-border-subtle: #ffe69c;
--bs-danger-border-subtle: #f1aeb5;
--bs-light-border-subtle: #e9ecef;
--bs-dark-border-subtle: #adb5bd;
--bs-white-rgb: 255, 255, 255;
--bs-black-rgb: 0, 0, 0;
--bs-font-sans-serif: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
--bs-font-monospace: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
--bs-gradient: linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));
--bs-body-font-family: var(--bs-font-sans-serif);
--bs-body-font-size: 1rem;
--bs-body-font-weight: 400;
--bs-body-line-height: 1.5;
--bs-body-color: #212529;
--bs-body-color-rgb: 33, 37, 41;
--bs-body-bg: #fff;
--bs-body-bg-rgb: 255, 255, 255;
--bs-emphasis-color: #000;
--bs-emphasis-color-rgb: 0, 0, 0;
--bs-secondary-color: rgba(33, 37, 41, 0.75);
--bs-secondary-color-rgb: 33, 37, 41;
--bs-secondary-bg: #e9ecef;
--bs-secondary-bg-rgb: 233, 236, 239;
--bs-tertiary-color: rgba(33, 37, 41, 0.5);
--bs-tertiary-color-rgb: 33, 37, 41;
--bs-tertiary-bg: #f8f9fa;
--bs-tertiary-bg-rgb: 248, 249, 250;
--bs-heading-color: inherit;
--bs-link-color: #0d6efd;
--bs-link-color-rgb: 13, 110, 253;
--bs-link-decoration: underline;
--bs-link-hover-color: #0a58ca;
--bs-link-hover-color-rgb: 10, 88, 202;
--bs-code-color: #d63384;
--bs-highlight-color: #212529;
--bs-highlight-bg: #fff3cd;
--bs-border-width: 1px;
--bs-border-style: solid;
--bs-border-color: #dee2e6;
--bs-border-color-translucent: rgba(0, 0, 0, 0.175);
--bs-border-radius: 0.375rem;
--bs-border-radius-sm: 0.25rem;
--bs-border-radius-lg: 0.5rem;
--bs-border-radius-xl: 1rem;
--bs-border-radius-xxl: 2rem;
--bs-border-radius-2xl: var(--bs-border-radius-xxl);
--bs-border-radius-pill: 50rem;
--bs-box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
--bs-box-shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
--bs-box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
--bs-box-shadow-inset: inset 0 1px 2px rgba(0, 0, 0, 0.075);
--bs-focus-ring-width: 0.25rem;
--bs-focus-ring-opacity: 0.25;
--bs-focus-ring-color: rgba(13, 110, 253, 0.25);
--bs-form-valid-color: #198754;
--bs-form-valid-border-color: #198754;
--bs-form-invalid-color: #dc3545;
--bs-form-invalid-border-color: #dc3545;
}
[data-bs-theme=dark] {
color-scheme: dark;
--bs-body-color: #dee2e6;
--bs-body-color-rgb: 222, 226, 230;
--bs-body-bg: #212529;
--bs-body-bg-rgb: 33, 37, 41;
--bs-emphasis-color: #fff;
--bs-emphasis-color-rgb: 255, 255, 255;
--bs-secondary-color: rgba(222, 226, 230, 0.75);
--bs-secondary-color-rgb: 222, 226, 230;
--bs-secondary-bg: #343a40;
--bs-secondary-bg-rgb: 52, 58, 64;
--bs-tertiary-color: rgba(222, 226, 230, 0.5);
--bs-tertiary-color-rgb: 222, 226, 230;
--bs-tertiary-bg: #2b3035;
--bs-tertiary-bg-rgb: 43, 48, 53;
--bs-primary-text-emphasis: #6ea8fe;
--bs-secondary-text-emphasis: #a7acb1;
--bs-success-text-emphasis: #75b798;
--bs-info-text-emphasis: #6edff6;
--bs-warning-text-emphasis: #ffda6a;
--bs-danger-text-emphasis: #ea868f;
--bs-light-text-emphasis: #f8f9fa;
--bs-dark-text-emphasis: #dee2e6;
--bs-primary-bg-subtle: #031633;
--bs-secondary-bg-subtle: #161719;
--bs-success-bg-subtle: #051b11;
--bs-info-bg-subtle: #032830;
--bs-warning-bg-subtle: #332701;
--bs-danger-bg-subtle: #2c0b0e;
--bs-light-bg-subtle: #343a40;
--bs-dark-bg-subtle: #1a1d20;
--bs-primary-border-subtle: #084298;
--bs-secondary-border-subtle: #41464b;
--bs-success-border-subtle: #0f5132;
--bs-info-border-subtle: #087990;
--bs-warning-border-subtle: #997404;
--bs-danger-border-subtle: #842029;
--bs-light-border-subtle: #495057;
--bs-dark-border-subtle: #343a40;
--bs-heading-color: inherit;
--bs-link-color: #6ea8fe;
--bs-link-hover-color: #8bb9fe;
--bs-link-color-rgb: 110, 168, 254;
--bs-link-hover-color-rgb: 139, 185, 254;
--bs-code-color: #e685b5;
--bs-highlight-color: #dee2e6;
--bs-highlight-bg: #664d03;
--bs-border-color: #495057;
--bs-border-color-translucent: rgba(255, 255, 255, 0.15);
--bs-form-valid-color: #75b798;
--bs-form-valid-border-color: #75b798;
--bs-form-invalid-color: #ea868f;
--bs-form-invalid-border-color: #ea868f;
}
*,
*::before,
*::after {
box-sizing: border-box;
}
@media (prefers-reduced-motion: no-preference) {
:root {
scroll-behavior: smooth;
}
}
body {
margin: 0;
font-family: var(--bs-body-font-family);
font-size: var(--bs-body-font-size);
font-weight: var(--bs-body-font-weight);
line-height: var(--bs-body-line-height);
color: var(--bs-body-color);
text-align: var(--bs-body-text-align);
background-color: var(--bs-body-bg);
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
hr {
margin: 1rem 0;
color: inherit;
border: 0;
border-top: var(--bs-border-width) solid;
opacity: 0.25;
}
h6, h5, h4, h3, h2, h1 {
margin-top: 0;
margin-bottom: 0.5rem;
font-weight: 500;
line-height: 1.2;
color: var(--bs-heading-color);
}
h1 {
font-size: calc(1.375rem + 1.5vw);
}
@media (min-width: 1200px) {
h1 {
font-size: 2.5rem;
}
}
h2 {
font-size: calc(1.325rem + 0.9vw);
}
@media (min-width: 1200px) {
h2 {
font-size: 2rem;
}
}
h3 {
font-size: calc(1.3rem + 0.6vw);
}
@media (min-width: 1200px) {
h3 {
font-size: 1.75rem;
}
}
h4 {
font-size: calc(1.275rem + 0.3vw);
}
@media (min-width: 1200px) {
h4 {
font-size: 1.5rem;
}
}
h5 {
font-size: 1.25rem;
}
h6 {
font-size: 1rem;
}
p {
margin-top: 0;
margin-bottom: 1rem;
}
abbr[title] {
-webkit-text-decoration: underline dotted;
text-decoration: underline dotted;
cursor: help;
-webkit-text-decoration-skip-ink: none;
text-decoration-skip-ink: none;
}
address {
margin-bottom: 1rem;
font-style: normal;
line-height: inherit;
}
ol,
ul {
padding-left: 2rem;
}
ol,
ul,
dl {
margin-top: 0;
margin-bottom: 1rem;
}
ol ol,
ul ul,
ol ul,
ul ol {
margin-bottom: 0;
}
dt {
font-weight: 700;
}
dd {
margin-bottom: 0.5rem;
margin-left: 0;
}
blockquote {
margin: 0 0 1rem;
}
b,
strong {
font-weight: bolder;
}
small {
font-size: 0.875em;
}
mark {
padding: 0.1875em;
color: var(--bs-highlight-color);
background-color: var(--bs-highlight-bg);
}
sub,
sup {
position: relative;
font-size: 0.75em;
line-height: 0;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
a {
color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));
text-decoration: underline;
}
a:hover {
--bs-link-color-rgb: var(--bs-link-hover-color-rgb);
}
a:not([href]):not([class]), a:not([href]):not([class]):hover {
color: inherit;
text-decoration: none;
}
pre,
code,
kbd,
samp {
font-family: var(--bs-font-monospace);
font-size: 1em;
}
pre {
display: block;
margin-top: 0;
margin-bottom: 1rem;
overflow: auto;
font-size: 0.875em;
}
pre code {
font-size: inherit;
color: inherit;
word-break: normal;
}
code {
font-size: 0.875em;
color: var(--bs-code-color);
word-wrap: break-word;
}
a > code {
color: inherit;
}
kbd {
padding: 0.1875rem 0.375rem;
font-size: 0.875em;
color: var(--bs-body-bg);
background-color: var(--bs-body-color);
border-radius: 0.25rem;
}
kbd kbd {
padding: 0;
font-size: 1em;
}
figure {
margin: 0 0 1rem;
}
img,
svg {
vertical-align: middle;
}
table {
caption-side: bottom;
border-collapse: collapse;
}
caption {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
color: var(--bs-secondary-color);
text-align: left;
}
th {
text-align: inherit;
text-align: -webkit-match-parent;
}
thead,
tbody,
tfoot,
tr,
td,
th {
border-color: inherit;
border-style: solid;
border-width: 0;
}
label {
display: inline-block;
}
button {
border-radius: 0;
}
button:focus:not(:focus-visible) {
outline: 0;
}
input,
button,
select,
optgroup,
textarea {
margin: 0;
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
button,
select {
text-transform: none;
}
[role=button] {
cursor: pointer;
}
select {
word-wrap: normal;
}
select:disabled {
opacity: 1;
}
[list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator {
display: none !important;
}
button,
[type=button],
[type=reset],
[type=submit] {
-webkit-appearance: button;
}
button:not(:disabled),
[type=button]:not(:disabled),
[type=reset]:not(:disabled),
[type=submit]:not(:disabled) {
cursor: pointer;
}
::-moz-focus-inner {
padding: 0;
border-style: none;
}
textarea {
resize: vertical;
}
fieldset {
min-width: 0;
padding: 0;
margin: 0;
border: 0;
}
legend {
float: left;
width: 100%;
padding: 0;
margin-bottom: 0.5rem;
font-size: calc(1.275rem + 0.3vw);
line-height: inherit;
}
@media (min-width: 1200px) {
legend {
font-size: 1.5rem;
}
}
legend + * {
clear: left;
}
::-webkit-datetime-edit-fields-wrapper,
::-webkit-datetime-edit-text,
::-webkit-datetime-edit-minute,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-year-field {
padding: 0;
}
::-webkit-inner-spin-button {
height: auto;
}
[type=search] {
-webkit-appearance: textfield;
outline-offset: -2px;
}
/* rtl:raw:
[type="tel"],
[type="url"],
[type="email"],
[type="number"] {
direction: ltr;
}
*/
::-webkit-search-decoration {
-webkit-appearance: none;
}
::-webkit-color-swatch-wrapper {
padding: 0;
}
::-webkit-file-upload-button {
font: inherit;
-webkit-appearance: button;
}
::file-selector-button {
font: inherit;
-webkit-appearance: button;
}
output {
display: inline-block;
}
iframe {
border: 0;
}
summary {
display: list-item;
cursor: pointer;
}
progress {
vertical-align: baseline;
}
[hidden] {
display: none !important;
}
/*# sourceMappingURL=bootstrap-reboot.css.map */

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1,594 +0,0 @@
/*!
* Bootstrap Reboot v5.3.2 (https://getbootstrap.com/)
* Copyright 2011-2023 The Bootstrap Authors
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
:root,
[data-bs-theme=light] {
--bs-blue: #0d6efd;
--bs-indigo: #6610f2;
--bs-purple: #6f42c1;
--bs-pink: #d63384;
--bs-red: #dc3545;
--bs-orange: #fd7e14;
--bs-yellow: #ffc107;
--bs-green: #198754;
--bs-teal: #20c997;
--bs-cyan: #0dcaf0;
--bs-black: #000;
--bs-white: #fff;
--bs-gray: #6c757d;
--bs-gray-dark: #343a40;
--bs-gray-100: #f8f9fa;
--bs-gray-200: #e9ecef;
--bs-gray-300: #dee2e6;
--bs-gray-400: #ced4da;
--bs-gray-500: #adb5bd;
--bs-gray-600: #6c757d;
--bs-gray-700: #495057;
--bs-gray-800: #343a40;
--bs-gray-900: #212529;
--bs-primary: #0d6efd;
--bs-secondary: #6c757d;
--bs-success: #198754;
--bs-info: #0dcaf0;
--bs-warning: #ffc107;
--bs-danger: #dc3545;
--bs-light: #f8f9fa;
--bs-dark: #212529;
--bs-primary-rgb: 13, 110, 253;
--bs-secondary-rgb: 108, 117, 125;
--bs-success-rgb: 25, 135, 84;
--bs-info-rgb: 13, 202, 240;
--bs-warning-rgb: 255, 193, 7;
--bs-danger-rgb: 220, 53, 69;
--bs-light-rgb: 248, 249, 250;
--bs-dark-rgb: 33, 37, 41;
--bs-primary-text-emphasis: #052c65;
--bs-secondary-text-emphasis: #2b2f32;
--bs-success-text-emphasis: #0a3622;
--bs-info-text-emphasis: #055160;
--bs-warning-text-emphasis: #664d03;
--bs-danger-text-emphasis: #58151c;
--bs-light-text-emphasis: #495057;
--bs-dark-text-emphasis: #495057;
--bs-primary-bg-subtle: #cfe2ff;
--bs-secondary-bg-subtle: #e2e3e5;
--bs-success-bg-subtle: #d1e7dd;
--bs-info-bg-subtle: #cff4fc;
--bs-warning-bg-subtle: #fff3cd;
--bs-danger-bg-subtle: #f8d7da;
--bs-light-bg-subtle: #fcfcfd;
--bs-dark-bg-subtle: #ced4da;
--bs-primary-border-subtle: #9ec5fe;
--bs-secondary-border-subtle: #c4c8cb;
--bs-success-border-subtle: #a3cfbb;
--bs-info-border-subtle: #9eeaf9;
--bs-warning-border-subtle: #ffe69c;
--bs-danger-border-subtle: #f1aeb5;
--bs-light-border-subtle: #e9ecef;
--bs-dark-border-subtle: #adb5bd;
--bs-white-rgb: 255, 255, 255;
--bs-black-rgb: 0, 0, 0;
--bs-font-sans-serif: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
--bs-font-monospace: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
--bs-gradient: linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));
--bs-body-font-family: var(--bs-font-sans-serif);
--bs-body-font-size: 1rem;
--bs-body-font-weight: 400;
--bs-body-line-height: 1.5;
--bs-body-color: #212529;
--bs-body-color-rgb: 33, 37, 41;
--bs-body-bg: #fff;
--bs-body-bg-rgb: 255, 255, 255;
--bs-emphasis-color: #000;
--bs-emphasis-color-rgb: 0, 0, 0;
--bs-secondary-color: rgba(33, 37, 41, 0.75);
--bs-secondary-color-rgb: 33, 37, 41;
--bs-secondary-bg: #e9ecef;
--bs-secondary-bg-rgb: 233, 236, 239;
--bs-tertiary-color: rgba(33, 37, 41, 0.5);
--bs-tertiary-color-rgb: 33, 37, 41;
--bs-tertiary-bg: #f8f9fa;
--bs-tertiary-bg-rgb: 248, 249, 250;
--bs-heading-color: inherit;
--bs-link-color: #0d6efd;
--bs-link-color-rgb: 13, 110, 253;
--bs-link-decoration: underline;
--bs-link-hover-color: #0a58ca;
--bs-link-hover-color-rgb: 10, 88, 202;
--bs-code-color: #d63384;
--bs-highlight-color: #212529;
--bs-highlight-bg: #fff3cd;
--bs-border-width: 1px;
--bs-border-style: solid;
--bs-border-color: #dee2e6;
--bs-border-color-translucent: rgba(0, 0, 0, 0.175);
--bs-border-radius: 0.375rem;
--bs-border-radius-sm: 0.25rem;
--bs-border-radius-lg: 0.5rem;
--bs-border-radius-xl: 1rem;
--bs-border-radius-xxl: 2rem;
--bs-border-radius-2xl: var(--bs-border-radius-xxl);
--bs-border-radius-pill: 50rem;
--bs-box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
--bs-box-shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
--bs-box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
--bs-box-shadow-inset: inset 0 1px 2px rgba(0, 0, 0, 0.075);
--bs-focus-ring-width: 0.25rem;
--bs-focus-ring-opacity: 0.25;
--bs-focus-ring-color: rgba(13, 110, 253, 0.25);
--bs-form-valid-color: #198754;
--bs-form-valid-border-color: #198754;
--bs-form-invalid-color: #dc3545;
--bs-form-invalid-border-color: #dc3545;
}
[data-bs-theme=dark] {
color-scheme: dark;
--bs-body-color: #dee2e6;
--bs-body-color-rgb: 222, 226, 230;
--bs-body-bg: #212529;
--bs-body-bg-rgb: 33, 37, 41;
--bs-emphasis-color: #fff;
--bs-emphasis-color-rgb: 255, 255, 255;
--bs-secondary-color: rgba(222, 226, 230, 0.75);
--bs-secondary-color-rgb: 222, 226, 230;
--bs-secondary-bg: #343a40;
--bs-secondary-bg-rgb: 52, 58, 64;
--bs-tertiary-color: rgba(222, 226, 230, 0.5);
--bs-tertiary-color-rgb: 222, 226, 230;
--bs-tertiary-bg: #2b3035;
--bs-tertiary-bg-rgb: 43, 48, 53;
--bs-primary-text-emphasis: #6ea8fe;
--bs-secondary-text-emphasis: #a7acb1;
--bs-success-text-emphasis: #75b798;
--bs-info-text-emphasis: #6edff6;
--bs-warning-text-emphasis: #ffda6a;
--bs-danger-text-emphasis: #ea868f;
--bs-light-text-emphasis: #f8f9fa;
--bs-dark-text-emphasis: #dee2e6;
--bs-primary-bg-subtle: #031633;
--bs-secondary-bg-subtle: #161719;
--bs-success-bg-subtle: #051b11;
--bs-info-bg-subtle: #032830;
--bs-warning-bg-subtle: #332701;
--bs-danger-bg-subtle: #2c0b0e;
--bs-light-bg-subtle: #343a40;
--bs-dark-bg-subtle: #1a1d20;
--bs-primary-border-subtle: #084298;
--bs-secondary-border-subtle: #41464b;
--bs-success-border-subtle: #0f5132;
--bs-info-border-subtle: #087990;
--bs-warning-border-subtle: #997404;
--bs-danger-border-subtle: #842029;
--bs-light-border-subtle: #495057;
--bs-dark-border-subtle: #343a40;
--bs-heading-color: inherit;
--bs-link-color: #6ea8fe;
--bs-link-hover-color: #8bb9fe;
--bs-link-color-rgb: 110, 168, 254;
--bs-link-hover-color-rgb: 139, 185, 254;
--bs-code-color: #e685b5;
--bs-highlight-color: #dee2e6;
--bs-highlight-bg: #664d03;
--bs-border-color: #495057;
--bs-border-color-translucent: rgba(255, 255, 255, 0.15);
--bs-form-valid-color: #75b798;
--bs-form-valid-border-color: #75b798;
--bs-form-invalid-color: #ea868f;
--bs-form-invalid-border-color: #ea868f;
}
*,
*::before,
*::after {
box-sizing: border-box;
}
@media (prefers-reduced-motion: no-preference) {
:root {
scroll-behavior: smooth;
}
}
body {
margin: 0;
font-family: var(--bs-body-font-family);
font-size: var(--bs-body-font-size);
font-weight: var(--bs-body-font-weight);
line-height: var(--bs-body-line-height);
color: var(--bs-body-color);
text-align: var(--bs-body-text-align);
background-color: var(--bs-body-bg);
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
hr {
margin: 1rem 0;
color: inherit;
border: 0;
border-top: var(--bs-border-width) solid;
opacity: 0.25;
}
h6, h5, h4, h3, h2, h1 {
margin-top: 0;
margin-bottom: 0.5rem;
font-weight: 500;
line-height: 1.2;
color: var(--bs-heading-color);
}
h1 {
font-size: calc(1.375rem + 1.5vw);
}
@media (min-width: 1200px) {
h1 {
font-size: 2.5rem;
}
}
h2 {
font-size: calc(1.325rem + 0.9vw);
}
@media (min-width: 1200px) {
h2 {
font-size: 2rem;
}
}
h3 {
font-size: calc(1.3rem + 0.6vw);
}
@media (min-width: 1200px) {
h3 {
font-size: 1.75rem;
}
}
h4 {
font-size: calc(1.275rem + 0.3vw);
}
@media (min-width: 1200px) {
h4 {
font-size: 1.5rem;
}
}
h5 {
font-size: 1.25rem;
}
h6 {
font-size: 1rem;
}
p {
margin-top: 0;
margin-bottom: 1rem;
}
abbr[title] {
-webkit-text-decoration: underline dotted;
text-decoration: underline dotted;
cursor: help;
-webkit-text-decoration-skip-ink: none;
text-decoration-skip-ink: none;
}
address {
margin-bottom: 1rem;
font-style: normal;
line-height: inherit;
}
ol,
ul {
padding-right: 2rem;
}
ol,
ul,
dl {
margin-top: 0;
margin-bottom: 1rem;
}
ol ol,
ul ul,
ol ul,
ul ol {
margin-bottom: 0;
}
dt {
font-weight: 700;
}
dd {
margin-bottom: 0.5rem;
margin-right: 0;
}
blockquote {
margin: 0 0 1rem;
}
b,
strong {
font-weight: bolder;
}
small {
font-size: 0.875em;
}
mark {
padding: 0.1875em;
color: var(--bs-highlight-color);
background-color: var(--bs-highlight-bg);
}
sub,
sup {
position: relative;
font-size: 0.75em;
line-height: 0;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
a {
color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));
text-decoration: underline;
}
a:hover {
--bs-link-color-rgb: var(--bs-link-hover-color-rgb);
}
a:not([href]):not([class]), a:not([href]):not([class]):hover {
color: inherit;
text-decoration: none;
}
pre,
code,
kbd,
samp {
font-family: var(--bs-font-monospace);
font-size: 1em;
}
pre {
display: block;
margin-top: 0;
margin-bottom: 1rem;
overflow: auto;
font-size: 0.875em;
}
pre code {
font-size: inherit;
color: inherit;
word-break: normal;
}
code {
font-size: 0.875em;
color: var(--bs-code-color);
word-wrap: break-word;
}
a > code {
color: inherit;
}
kbd {
padding: 0.1875rem 0.375rem;
font-size: 0.875em;
color: var(--bs-body-bg);
background-color: var(--bs-body-color);
border-radius: 0.25rem;
}
kbd kbd {
padding: 0;
font-size: 1em;
}
figure {
margin: 0 0 1rem;
}
img,
svg {
vertical-align: middle;
}
table {
caption-side: bottom;
border-collapse: collapse;
}
caption {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
color: var(--bs-secondary-color);
text-align: right;
}
th {
text-align: inherit;
text-align: -webkit-match-parent;
}
thead,
tbody,
tfoot,
tr,
td,
th {
border-color: inherit;
border-style: solid;
border-width: 0;
}
label {
display: inline-block;
}
button {
border-radius: 0;
}
button:focus:not(:focus-visible) {
outline: 0;
}
input,
button,
select,
optgroup,
textarea {
margin: 0;
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
button,
select {
text-transform: none;
}
[role=button] {
cursor: pointer;
}
select {
word-wrap: normal;
}
select:disabled {
opacity: 1;
}
[list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator {
display: none !important;
}
button,
[type=button],
[type=reset],
[type=submit] {
-webkit-appearance: button;
}
button:not(:disabled),
[type=button]:not(:disabled),
[type=reset]:not(:disabled),
[type=submit]:not(:disabled) {
cursor: pointer;
}
::-moz-focus-inner {
padding: 0;
border-style: none;
}
textarea {
resize: vertical;
}
fieldset {
min-width: 0;
padding: 0;
margin: 0;
border: 0;
}
legend {
float: right;
width: 100%;
padding: 0;
margin-bottom: 0.5rem;
font-size: calc(1.275rem + 0.3vw);
line-height: inherit;
}
@media (min-width: 1200px) {
legend {
font-size: 1.5rem;
}
}
legend + * {
clear: right;
}
::-webkit-datetime-edit-fields-wrapper,
::-webkit-datetime-edit-text,
::-webkit-datetime-edit-minute,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-year-field {
padding: 0;
}
::-webkit-inner-spin-button {
height: auto;
}
[type=search] {
-webkit-appearance: textfield;
outline-offset: -2px;
}
[type="tel"],
[type="url"],
[type="email"],
[type="number"] {
direction: ltr;
}
::-webkit-search-decoration {
-webkit-appearance: none;
}
::-webkit-color-swatch-wrapper {
padding: 0;
}
::-webkit-file-upload-button {
font: inherit;
-webkit-appearance: button;
}
::file-selector-button {
font: inherit;
-webkit-appearance: button;
}
output {
display: inline-block;
}
iframe {
border: 0;
}
summary {
display: list-item;
cursor: pointer;
}
progress {
vertical-align: baseline;
}
[hidden] {
display: none !important;
}
/*# sourceMappingURL=bootstrap-reboot.rtl.css.map */

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1,27 +0,0 @@
@charset "UTF-8";
.myBody{
background-color: rgba(255,187,248,0.50);
}
.imgArticle{
width: 15em;
margin: 1em;
}
.enTitre{
font-size: large;
}
.entete{
font-size: xxx-large;
}
.caseInfo{
margin: 1em;
padding: 1em;
background-color: rgba(255,185,251,0.61);
}
.dnconnect{
padding: 1em;
display: flex;
justify-content: right;
}
.margOp{
margin: 1em;
}

@ -3,13 +3,9 @@
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--Boostrap--> <title>Login</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<!--CSS-->
<link rel="stylesheet" href="/~rorossetto/Php_RSS/fluxRSS/templates/CSS/myStyle.css" >
<title class="enTitre">Login</title>
</head> </head>
<body class="myBody"> <body>
<div align="center"> <div align="center">
{% if dVue is defined %} {% if dVue is defined %}
@ -21,33 +17,42 @@
{% endif %} {% endif %}
{% endif %} {% endif %}
<h1 class="d-flex justify-content-center entete margOp">Login</h1> <h1>Login</h1>
<form method="POST" class="form-floating" name="myform" id="myform"> <form method="POST" name="myform" id="myform">
<table> <table>
<tr> <tr>
<td>Nom</td> <td>Nom</td>
<td> <td>
<input class="margOp" name="username" id="username" type="text" size="20" /> <input name="username" id="username" type="text" size="20" />
</td> </td>
</tr> </tr>
<tr> <tr>
<td>Password</td> <td>Password</td>
<td> <td>
<input class="margOp" type="password" id="password" name="password" required> <input type="password" id="password" name="password" required>
</td> </td>
</tr> </tr>
</table> </table>
<table> <table>
<tr> <tr>
<td><input class="margOp" type="submit" value="Envoyer" /></td> <td><input type="submit" value="Envoyer" /></td>
<td><input class="margOp" type="reset" value="Rétablir" /></td> <td><input type="reset" value="Rétablir" /></td>
</tr> </tr>
</table> </table>
<!-- action !!!!!!!!!! --> <!-- action !!!!!!!!!! -->
<input type="hidden" name="action" value="connection" /> <input type="hidden" name="action" value="connection" />
</form> </form>
<a href="/~rorossetto/Php_RSS/fluxRSS/user/" class="modal-content">Not a member? Go to Articles</a> <a href="/~mapoint2/SAE/Php_RSS/fluxRSS/user/">Not a member? Go to Articles</a>
</div> </div>
</body> </body>
</html> </html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Login</title>
</head>
<body>

@ -3,9 +3,9 @@
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<title>Erreur</title> <title>Erreur</title>
</head> </head>
<body> <body>
<h1>ERREUR page !!!!!</h1> <h1>ERREUR page !!!!!</h1>
{% if dVueEreur is defined %} {% if dVueEreur is defined %}

@ -2,44 +2,24 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<!-- Bootstrap -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<!-- CSS -->
<link rel="stylesheet" href="/~rorossetto/Php_RSS/fluxRSS/templates/CSS/myStyle.css" >
<title>All Articles</title> <title>All Articles</title>
</head> </head>
<body class="myBody margOp"> <body>
<div> {% for value in dVue.data %}
{% if not isAdmin %} <p>
<a href="/~rorossetto/Php_RSS/fluxRSS/admin/connection" class="btn dnconnect" >Connect</a> {% for article in value %}
{% else %} <p>
<a href="/~rorossetto/Php_RSS/fluxRSS/user/deconnection" class="btn dnconnect">Déconnection</a> {{article}}
{% endif %}
<div>
<h1 class="d-flex justify-content-center entete">Actualités</h1>
</div>
<form method="POST" action="changeNbArticle">
<input name="nbArticle" type="number" min="0">
<button type="submit">Change number of articles</button>
</form>
</div>
{% if dVue.data is defined %}
{% for article in dVue.data %}
<p class="caseInfo">
{{article.dateStr()}}<br>
<img class="img-thumbnail imgArticle" src="{{ article.getMediaContent }}"/>
<a class="modal-content enTitre" href="{{ article.getLink() }}" target="_blank">{{ article.getTitle() }}</a>
{{ article.getDescription() }}
</p> </p>
{% endfor %} {% endfor %}
</p>
{% endfor %}
user
{% if not isAdmin %}
<a href="/~mapoint2/SAE/Php_RSS/fluxRSS/admin/connection">Connect</a>
{% else %} {% else %}
<p class="d-flex justify-content-center enTitre"> Pas d'articles à afficher</p> <a href="/~mapoint2/SAE/Php_RSS/fluxRSS/admin/">Vue admin</a>
<a href="/~mapoint2/SAE/Php_RSS/fluxRSS/user/deconnection">Déconnection</a>
{% endif %} {% endif %}
<script>
// Actualiser la page toutes les 3 heures
setTimeout(function(){
location.reload();
}, 10800000);
</script>
</body> </body>
</html> </html>

@ -2,38 +2,20 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<!-- CSS -->
<link rel="stylesheet" href="/~rorossetto/Php_RSS/fluxRSS/templates/CSS/myStyle.css" >
<title>All Articles</title> <title>All Articles</title>
</head> </head>
<body class="myBody margOp"> <body>
<a class="btn dnconnect" href="/~rorossetto/Php_RSS/fluxRSS/admin/deconnection">Déconnection</a> admin
<a class="btn" href="/~rorossetto/Php_RSS/fluxRSS/admin/listFlux">Vue flux</a> {% for value in dVue.data %}
<div class="margOp"> <p>
<h1 class="d-flex justify-content-center entete">Vue des articles</h1> {% for article in value %}
</div> <p>
<form class="margOp" method="POST" action="changeNbArticle"> {{article}}
<input name="nbArticleAdmin" type="number" min="0"> </p>
<button type="submit">Change number of articles</button> {% endfor %}
</form> </p>
{% if dVue.data is defined %} {% endfor %}
{% for article in dVue.data %} <a href="/~mapoint2/SAE/Php_RSS/fluxRSS/">Vue user</a>
<p class="caseInfo"> <a href="/~mapoint2/SAE/Php_RSS/fluxRSS/admin/deconnection">Déconnection</a>
{{article.dateStr()}}<br>
<img class="imgArticle" src="{{ article.getMediaContent }}"/><br>
<a class="modal-content enTitre" href="{{ article.getLink() }}"target="_blank">{{ article.getTitle() }}</a>
{{ article.getDescription() }}
</p>
{% endfor %}
{% else %}
<p class="d-flex justify-content-center enTitre">Pas d'articles à afficher</p>
{% endif %}
<script>
// Actualiser la page toutes les 3 heures
setTimeout(function(){
location.reload();
}, 10800000);
</script>
</body> </body>
</html> </html>

@ -1,33 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<!-- CSS -->
<link rel="stylesheet" href="/~rorossetto/Php_RSS/fluxRSS/templates/CSS/myStyle.css" >
<title>All Flux</title>
</head>
<body class="myBody margOp">
<a class="btn" href="/~rorossetto/Php_RSS/fluxRSS/admin/">Vue article</a>
<div class="margOp">
<h1 class="d-flex justify-content-center entete">Liste flux</h1>
</div>
{% if dVue.data is defined %}
{% for value in dVue.data %}
<div class="margOp enTitre caseInfo">
{{ value.getFlux() }}
<form method="post" action="deleteFlux">
<input type="hidden" name="flux" value="{{ value.getId() }}">
<button class="margOp" type="submit">Delete Flux</button>
</form>
</div>
{% endfor %}
{% else %}
<p class="justify-content-center d-flex enTitre">Pas de flux présent</p>
{% endif %}
<form method="POST" action="ajoutFlux">
<input name="fluxAdd" type="text">
<button type="submit">Ajouter Flux</button>
</form>
</body>
</html>

@ -6,13 +6,12 @@ $vendorDir = dirname(__DIR__);
$baseDir = dirname($vendorDir); $baseDir = dirname($vendorDir);
return array( return array(
'src\\' => array($baseDir . '/src'), 'model\\' => array($baseDir . '/model'),
'model\\' => array($baseDir . '/src/model'), 'metier\\' => array($baseDir . '/metier'),
'metier\\' => array($baseDir . '/src/metier'), 'controleur\\' => array($baseDir . '/controleur'),
'controleur\\' => array($baseDir . '/src/controleur'), 'config\\' => array($baseDir . '/config'),
'config\\' => array($baseDir . '/src/config'),
'Twig\\' => array($vendorDir . '/twig/twig/src'), 'Twig\\' => array($vendorDir . '/twig/twig/src'),
'Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'), 'Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'),
'Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'), 'Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'),
'DAL\\' => array($baseDir . '/src/DAL'), 'DAL\\' => array($baseDir . '/DAL'),
); );

@ -12,10 +12,6 @@ class ComposerStaticInita6287a55fe354aae4af95d1e4395c915
); );
public static $prefixLengthsPsr4 = array ( public static $prefixLengthsPsr4 = array (
's' =>
array (
'src\\' => 4,
),
'm' => 'm' =>
array ( array (
'model\\' => 6, 'model\\' => 6,
@ -42,25 +38,21 @@ class ComposerStaticInita6287a55fe354aae4af95d1e4395c915
); );
public static $prefixDirsPsr4 = array ( public static $prefixDirsPsr4 = array (
'src\\' =>
array (
0 => __DIR__ . '/../..' . '/src',
),
'model\\' => 'model\\' =>
array ( array (
0 => __DIR__ . '/../..' . '/src/model', 0 => __DIR__ . '/../..' . '/model',
), ),
'metier\\' => 'metier\\' =>
array ( array (
0 => __DIR__ . '/../..' . '/src/metier', 0 => __DIR__ . '/../..' . '/metier',
), ),
'controleur\\' => 'controleur\\' =>
array ( array (
0 => __DIR__ . '/../..' . '/src/controleur', 0 => __DIR__ . '/../..' . '/controleur',
), ),
'config\\' => 'config\\' =>
array ( array (
0 => __DIR__ . '/../..' . '/src/config', 0 => __DIR__ . '/../..' . '/config',
), ),
'Twig\\' => 'Twig\\' =>
array ( array (
@ -76,7 +68,7 @@ class ComposerStaticInita6287a55fe354aae4af95d1e4395c915
), ),
'DAL\\' => 'DAL\\' =>
array ( array (
0 => __DIR__ . '/../..' . '/src/DAL', 0 => __DIR__ . '/../..' . '/DAL',
), ),
); );

Loading…
Cancel
Save