This commit is contained in:
Fred Tempez 2024-10-17 21:13:24 +02:00
parent e6431005bd
commit 918a6ad9e8
2 changed files with 28 additions and 8 deletions

View File

@ -41,4 +41,12 @@ Options -Indexes
# ne pas supprimer la ligne URL rewriting !
# URL rewriting
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /ZwiiCampus/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?$1 [L]
</IfModule>
# URL rewriting

View File

@ -1151,12 +1151,12 @@ class user extends common
// Exclure les espaces des cours
/*
foreach (array_keys($this->getData(['course'])) as $courseId) {
self::$sharePath = array_filter(self::$sharePath, function ($key) use ($courseId) {
return strpos($key, $courseId) === false;
});
}
*/
foreach (array_keys($this->getData(['course'])) as $courseId) {
self::$sharePath = array_filter(self::$sharePath, function ($key) use ($courseId) {
return strpos($key, $courseId) === false;
});
}
*/
self::$sharePath = array_flip(self::$sharePath);
self::$sharePath = array_merge(['none' => 'Aucun Accès'], self::$sharePath);
@ -1415,8 +1415,20 @@ class user extends common
public function autologin()
{
var_dump($_GET);
die();
// Récupère l'URL complète
$url = $_SERVER['REQUEST_URI'];
// Extrait la partie après le "?" dans l'URL
$parsedUrl = parse_url($url);
if (isset($parsedUrl['query'])) {
// Analyse les paramètres à la main
parse_str($parsedUrl['query'], $params);
// Affiche les paramètres
var_dump($params);
} else {
echo "Aucun paramètre trouvé dans l'URL.";
}
}
/**