Redir the frontpage to home

This commit is contained in:
danpros 2021-04-15 12:11:23 +07:00
commit e7848acf6f
2 changed files with 5 additions and 1 deletions

View file

@ -3002,6 +3002,11 @@ get('/:static/:sub', function ($static, $sub) {
$url = site_url() . 'search/' . remove_accent($search);
header("Location: $url");
}
if ($static === 'front') {
$redir = site_url();
header("location: $redir", TRUE, 301);
}
$father_post = get_static_post($static);
if (!$father_post) {

View file

@ -6,7 +6,6 @@ if(PHP_VERSION_ID < 70300) {
session_set_cookie_params(['samesite' => $samesite]);
}
session_set_cookie_params(['samesite' => 'Strict']);
if (isset($_COOKIE['PHPSESSID']))
session_start();