premier test de route
continuous-integration/drone/push Build is passing Details

pull/130/head
Vincent ASTOLFI 2 years ago
parent eff76fb7b4
commit 352920f5e1

@ -2,7 +2,7 @@
//prefixe //prefixe
$rep=__DIR__.'/../'; $rep=__DIR__.'/../';
$dsn='mysql:host=10.9.0.67;dbname='.getenv("MARIADB_DATABASE"); $dsn='mysql:host=10.9.0.65;dbname='.getenv("MARIADB_DATABASE");
$dbname=getenv("MARIADB_DATABASE"); $dbname=getenv("MARIADB_DATABASE");
$usr=getenv("MARIADB_USER"); $usr=getenv("MARIADB_USER");
$mdp=getenv("MARIADB_PASSWORD"); $mdp=getenv("MARIADB_PASSWORD");

@ -0,0 +1,10 @@
<?php
class Controller{
function __construct(){
echo "tu es bien arrivé";
}
}
?>

@ -5,6 +5,14 @@ require_once(__DIR__.'/config/Config.php');
require_once(__DIR__.'/config/Autoload.php'); require_once(__DIR__.'/config/Autoload.php');
Autoload::charger(); Autoload::charger();
// loading a controler $router = new AltoRouter();
$cont = new FrontControler(); $router->map('GET|POST',"/","test");
$match=$router->match();
if(!$match){echo "404"; die;}
if($match){
$cont = new Controller();
}
?> ?>
Loading…
Cancel
Save