-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1416 Simplifier configuration historique sur le parameters.yml/confi…
…g.yml (#1421) * #1416 bdd * !1416 divers * !1416 mails * !1416 afup * !1416 rib et rib_ce * !1416 planete * !1416 site * !1416 git & sympa * !1416 bureau * !1416 nettoyage final * Corrige le RIB de PROD Co-authored-by: Adrien Gallou <[email protected]> * Corrige la date du changement du RIB --------- Co-authored-by: Adrien Gallou <[email protected]>
- Loading branch information
Showing
45 changed files
with
210 additions
and
644 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +0,0 @@ | ||
<?php | ||
|
||
// Initialisation | ||
ob_start(); | ||
|
||
// Inclusion de l'autoload de composer | ||
require_once dirname(__FILE__) . '/../../vendor/autoload.php'; | ||
|
||
require_once dirname(__FILE__).'/../../sources/Afup/fonctions.php'; | ||
|
||
// Configuration | ||
$conf = new \Afup\Site\Utils\Configuration(dirname(__FILE__).'/../../configs/application/config.php'); | ||
$GLOBALS['AFUP_CONF'] = $conf; | ||
error_reporting($conf->obtenir('divers|niveau_erreur')); | ||
ini_set('display_errors', $conf->obtenir('divers|afficher_erreurs')); | ||
ini_set('include_path', ini_get('include_path') . PATH_SEPARATOR . dirname(__FILE__).'/../../dependencies/PEAR/' . PATH_SEPARATOR . dirname(__FILE__).'/../../dependencies/'); | ||
header('Content-type: text/html; charset=UTF-8'); | ||
|
||
// On détermine sur quel sous-site on est | ||
$serveur = ""; | ||
$url = $_SERVER['REQUEST_URI']; | ||
if (strrpos($url, '?') !== false) { | ||
$position = strrpos($url, '?'); | ||
$url = substr($url, 0, $position); | ||
} | ||
$position = strrpos($url, '/'); | ||
$url = substr($_SERVER['REQUEST_URI'], 0, $position); | ||
$parties = explode('/', $url); | ||
$sous_site = array_pop($parties); | ||
if (empty($sous_site) and strpos($_SERVER['HTTP_HOST'], "planete") !== false) { | ||
$sous_site = "planete"; | ||
$serveur = "https://afup.org"; | ||
} | ||
|
||
// Initialisation de Smarty | ||
$smarty = new Smarty; | ||
$smarty->template_dir = array(dirname(__FILE__).'/../../htdocs/templates/' . $sous_site . '/', | ||
dirname(__FILE__).'/../../htdocs/templates/commun/'); | ||
$smarty->compile_dir = dirname(__FILE__).'/../../htdocs/cache/templates'; | ||
$smarty->compile_id = $sous_site; | ||
$smarty->use_sub_dirs = true; | ||
$smarty->compile_check = true; | ||
$smarty->php_handling = SMARTY_PHP_ALLOW; | ||
$smarty->assign('url_base', 'http://' . $_SERVER['HTTP_HOST'] . '/'); | ||
$smarty->assign('chemin_template', $serveur.$conf->obtenir('web|path').'templates/' . $sous_site . '/'); | ||
$smarty->assign('chemin_javascript', $serveur.$conf->obtenir('web|path').'javascript/'); | ||
|
||
// Initialisation de la couche d'abstraction de la base de données | ||
$bdd = new \Afup\Site\Utils\Base_De_Donnees($conf->obtenir('bdd|hote'), | ||
$conf->obtenir('bdd|base'), | ||
$conf->obtenir('bdd|utilisateur'), | ||
$conf->obtenir('bdd|mot_de_passe')); | ||
$bdd->executer("SET NAMES 'utf8'"); | ||
|
||
require_once(dirname(__FILE__) . '/../../sources/Afup/Bootstrap/commonStart.php'); | ||
Oops, something went wrong.