2018-04-02 08:29:19 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* This file is part of Zwii.
|
|
|
|
*
|
|
|
|
* For full copyright and license information, please see the LICENSE
|
|
|
|
* file that was distributed with this source code.
|
|
|
|
*
|
|
|
|
* @author Rémi Jean <remi.jean@outlook.com>
|
|
|
|
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
2019-11-18 08:53:43 +01:00
|
|
|
* @author Frédéric Tempez <frederic.tempez@outlook.com>
|
2024-01-14 19:31:28 +01:00
|
|
|
* @copyright Copyright (C) 2018-2024, Frédéric Tempez
|
2022-12-29 17:02:20 +01:00
|
|
|
* @license CC Attribution-NonCommercial-NoDerivatives 4.0 International
|
2020-09-01 20:48:40 +02:00
|
|
|
* @link http://zwiicms.fr/
|
2018-04-02 08:29:19 +02:00
|
|
|
*/
|
|
|
|
|
2020-11-01 08:16:30 +01:00
|
|
|
/**
|
|
|
|
* Initialisation de Zwii
|
|
|
|
*/
|
2021-12-23 10:14:25 +01:00
|
|
|
// Remplace la directive htaccess
|
|
|
|
ini_set('session.use_trans_sid', FALSE);
|
2024-09-06 09:34:15 +02:00
|
|
|
// Crée un identifiant unique pour chaque site en fonction du nom de domaine ou autre
|
2024-09-08 14:59:09 +02:00
|
|
|
$siteId = md5($_SERVER['SERVER_NAME'] . $_SERVER['SCRIPT_FILENAME']); // Ou utilise un autre identifiant unique pour chaque site
|
2024-09-06 09:34:15 +02:00
|
|
|
// Change le nom de la session en fonction de cet identifiant
|
|
|
|
session_name('zwii_session_' . $siteId);
|
2021-12-23 10:14:25 +01:00
|
|
|
// Démarre la session
|
2020-11-01 08:16:30 +01:00
|
|
|
session_start();
|
|
|
|
|
2023-02-09 10:36:52 +01:00
|
|
|
// Contrôle des conditions de fonctionnement
|
|
|
|
include_once('core/include/checkup.php');
|
2018-04-02 08:29:19 +02:00
|
|
|
|
2023-02-10 09:58:55 +01:00
|
|
|
// Mise à jour du système de BDD
|
|
|
|
include_once('core/include/pre-update.php');
|
|
|
|
|
2020-10-20 18:32:25 +02:00
|
|
|
/*
|
2023-02-10 09:58:55 +01:00
|
|
|
*Localisation par défaut
|
2020-11-01 08:27:32 +01:00
|
|
|
|
|
|
|
* Locales :
|
|
|
|
* french : free.fr
|
|
|
|
* fr_FR : XAMPP Macos
|
|
|
|
* fr_FR.utf8 : la majorité
|
2020-11-01 08:16:30 +01:00
|
|
|
*/
|
2020-11-01 08:27:32 +01:00
|
|
|
date_default_timezone_set('Europe/Paris');
|
2023-02-10 09:58:55 +01:00
|
|
|
setlocale (LC_ALL, 'fr_FR.UTF8', 'fr_FR', 'french');
|
2019-05-03 09:48:06 +02:00
|
|
|
|
2020-10-20 18:32:25 +02:00
|
|
|
/**
|
|
|
|
* Chargement des classes
|
|
|
|
*/
|
2019-12-15 10:47:18 +01:00
|
|
|
require 'core/class/autoload.php';
|
|
|
|
autoload::autoloader();
|
2020-10-20 18:32:25 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Chargement du coeur
|
|
|
|
*/
|
2018-04-02 08:29:19 +02:00
|
|
|
$core = new core;
|
2023-12-24 14:30:12 +01:00
|
|
|
spl_autoload_register('core::autoload');
|
2020-10-19 20:48:18 +02:00
|
|
|
echo $core->router();
|
2023-12-24 14:30:12 +01:00
|
|
|
|