Improve configs files
This commit is contained in:
parent
24d3336d00
commit
6cdfb46025
|
@ -1,4 +1,4 @@
|
||||||
config/conf.php
|
config/config.php
|
||||||
.idea
|
.idea
|
||||||
/public/uploads
|
/public/uploads
|
||||||
/tmp
|
/tmp
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?php
|
<?php
|
||||||
include 'conf.php';
|
include 'config.php';
|
||||||
|
|
||||||
use App\Framework\Twig\UrlExtension;
|
use App\Framework\Twig\UrlExtension;
|
||||||
use Framework\Middleware\CsrfMiddleware;
|
use Framework\Middleware\CsrfMiddleware;
|
||||||
|
@ -48,6 +48,6 @@ return [
|
||||||
},
|
},
|
||||||
// MAILER
|
// MAILER
|
||||||
'mail.to' => 'admin@gmarche-testmail.com',
|
'mail.to' => 'admin@gmarche-testmail.com',
|
||||||
'mail.from' => 'no-reply@admin.fr',
|
'mail.from' => '$mail_from',
|
||||||
Swift_Mailer::class => \DI\factory(\Framework\SwiftMailerFactory::class)
|
Swift_Mailer::class => \DI\factory(\Framework\SwiftMailerFactory::class)
|
||||||
];
|
];
|
|
@ -3,4 +3,5 @@
|
||||||
$db_username = '';
|
$db_username = '';
|
||||||
$db_password = '';
|
$db_password = '';
|
||||||
$db_name = '';
|
$db_name = '';
|
||||||
|
$mail_from = '';
|
||||||
$g1_node = 'https://duniter-g1.p2p.legal';
|
$g1_node = 'https://duniter-g1.p2p.legal';
|
|
@ -3,7 +3,7 @@ ini_set('display_errors', 0);
|
||||||
|
|
||||||
if ($_POST['produit']!== '' && $_POST['vendeur']!== null && $_POST['quantite']>0 && $_POST['prix']>=0) {
|
if ($_POST['produit']!== '' && $_POST['vendeur']!== null && $_POST['quantite']>0 && $_POST['prix']>=0) {
|
||||||
// Connexion à la base de données
|
// Connexion à la base de données
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
||||||
// Récupération des informations du formulaire
|
// Récupération des informations du formulaire
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
if(isset($_POST['produit']) && isset($_POST['acheteur']) && isset($_POST['quantite']) )
|
if(isset($_POST['produit']) && isset($_POST['acheteur']) && isset($_POST['quantite']) )
|
||||||
{
|
{
|
||||||
// Connexion à la base de données
|
// Connexion à la base de données
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
||||||
// Récupération des informations du formulaire
|
// Récupération des informations du formulaire
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?php
|
<?php
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
if($_POST['id'] !== null)
|
if($_POST['id'] !== null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?php
|
<?php
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
if($_POST['id_r'] !== null)
|
if($_POST['id_r'] !== null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
ini_set('display_errors', 0);
|
ini_set('display_errors', 0);
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
if(isset($_GET['vendeur']))
|
if(isset($_GET['vendeur']))
|
||||||
{
|
{
|
||||||
// Get public key from pseudo
|
// Get public key from pseudo
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
ini_set('display_errors', 0);
|
ini_set('display_errors', 0);
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
$antenne_slug = $_GET['antenne_slug'];
|
$antenne_slug = $_GET['antenne_slug'];
|
||||||
$nom_connecte = $_GET['nom_connecte'];
|
$nom_connecte = $_GET['nom_connecte'];
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
ini_set('display_errors', 0);
|
ini_set('display_errors', 0);
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
$antenne_slug = $_GET['antenne_slug'];
|
$antenne_slug = $_GET['antenne_slug'];
|
||||||
$nom_connecte = $_GET['nom_connecte'];
|
$nom_connecte = $_GET['nom_connecte'];
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
include '../../config/conf.php';
|
include '../../config/config.php';
|
||||||
|
|
||||||
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
$bdd = new \PDO("mysql:host=$db_server;dbname=$db_name", $db_username, $db_password);
|
||||||
|
|
||||||
|
|
|
@ -24,8 +24,8 @@ require 'vendor/autoload.php';
|
||||||
$chemin = $_SERVER['DOCUMENT_ROOT'];
|
$chemin = $_SERVER['DOCUMENT_ROOT'];
|
||||||
$chemin_new = substr($chemin,0,-6);
|
$chemin_new = substr($chemin,0,-6);
|
||||||
|
|
||||||
$app = (new \Framework\App( $chemin_new .'/config/config.php'))
|
$app = (new \Framework\App( $chemin_new .'/config/apply.php'))
|
||||||
//$app = (new \Framework\App( '../config/config.php'))
|
//$app = (new \Framework\App( '../config/apply.php'))
|
||||||
->addModule(AdminModule::class)
|
->addModule(AdminModule::class)
|
||||||
->addModule(ContactModule::class)
|
->addModule(ContactModule::class)
|
||||||
->addModule(ProductModule::class)
|
->addModule(ProductModule::class)
|
||||||
|
|
Loading…
Reference in New Issue