Moved index and static files in a webroot directory.
* Security improvement: index.php and static files are now in a webroot directory. The webserver should point to this directory instead of the one containing all the code and the configuration.
@ -1,10 +1,11 @@
|
||||
<?php
|
||||
require __DIR__ . "/vendor/autoload.php";
|
||||
require __DIR__ . "/src/models/Poll.php";
|
||||
require __DIR__ . "/src/Format.php";
|
||||
require __DIR__ . "/config/app.php";
|
||||
require __DIR__ . "/../vendor/autoload.php";
|
||||
require __DIR__ . "/../src/models/Poll.php";
|
||||
require __DIR__ . "/../src/Format.php";
|
||||
require __DIR__ . "/../config/app.php";
|
||||
|
||||
Flight::set("flight.base_url", $VERLAINE["app_url"]);
|
||||
Flight::set("flight.views.path", "../views");
|
||||
|
||||
Flight::route("POST /polls", function () {
|
||||
$request = Flight::request();
|
Before Width: | Height: | Size: 531 KiB After Width: | Height: | Size: 531 KiB |
Before Width: | Height: | Size: 541 KiB After Width: | Height: | Size: 541 KiB |
Before Width: | Height: | Size: 532 KiB After Width: | Height: | Size: 532 KiB |
Before Width: | Height: | Size: 539 KiB After Width: | Height: | Size: 539 KiB |
Before Width: | Height: | Size: 516 KiB After Width: | Height: | Size: 516 KiB |
Before Width: | Height: | Size: 526 KiB After Width: | Height: | Size: 526 KiB |
Before Width: | Height: | Size: 518 KiB After Width: | Height: | Size: 518 KiB |
Before Width: | Height: | Size: 521 KiB After Width: | Height: | Size: 521 KiB |
Before Width: | Height: | Size: 534 KiB After Width: | Height: | Size: 534 KiB |
Before Width: | Height: | Size: 518 KiB After Width: | Height: | Size: 518 KiB |
Before Width: | Height: | Size: 526 KiB After Width: | Height: | Size: 526 KiB |
Before Width: | Height: | Size: 526 KiB After Width: | Height: | Size: 526 KiB |
Before Width: | Height: | Size: 528 KiB After Width: | Height: | Size: 528 KiB |
Before Width: | Height: | Size: 535 KiB After Width: | Height: | Size: 535 KiB |
Before Width: | Height: | Size: 433 KiB After Width: | Height: | Size: 433 KiB |
Before Width: | Height: | Size: 469 KiB After Width: | Height: | Size: 469 KiB |
Before Width: | Height: | Size: 460 KiB After Width: | Height: | Size: 460 KiB |
Before Width: | Height: | Size: 424 KiB After Width: | Height: | Size: 424 KiB |