1
0

fix 404 page http code

This commit is contained in:
Mike Schwörer 2020-01-20 18:09:35 +01:00
parent 5acdd0a69a
commit 3c3d0bf51b
Signed by: Mikescher
GPG Key ID: D3C7172E0A70F8CF
3 changed files with 2 additions and 6 deletions

View File

@ -90,9 +90,6 @@ class Website
{ {
try try
{ {
$frameOpt->statuscode = 404;
$frameOpt->title = 'Page not found';
$route = URLRoute::getNotFoundRoute($uri); $route = URLRoute::getNotFoundRoute($uri);
$route->parameter['message'] = $message; $route->parameter['message'] = $message;
@ -119,9 +116,6 @@ class Website
try try
{ {
if ($frameOpt === null) $frameOpt = new PageFrameOptions(); if ($frameOpt === null) $frameOpt = new PageFrameOptions();
$frameOpt->statuscode = 500;
$frameOpt->title = 'Internal Server Error';
$frameOpt->frame = 'error_frame.php'; $frameOpt->frame = 'error_frame.php';
$route = URLRoute::getServerErrorRoute($_SERVER['REQUEST_URI']); $route = URLRoute::getServerErrorRoute($_SERVER['REQUEST_URI']);

View File

@ -10,6 +10,7 @@ require_once (__DIR__ . '/../internals/website.php');
$message = isset($ROUTE->parameter['message']) ? $ROUTE->parameter['message'] : ''; $message = isset($ROUTE->parameter['message']) ? $ROUTE->parameter['message'] : '';
$FRAME_OPTIONS->title = $message; $FRAME_OPTIONS->title = $message;
$FRAME_OPTIONS->statuscode = 404;
$FRAME_OPTIONS->canonical_url = null; $FRAME_OPTIONS->canonical_url = null;
$FRAME_OPTIONS->activeHeader = null; $FRAME_OPTIONS->activeHeader = null;
$FRAME_OPTIONS->contentCSSClasses []= 'content-fullheight'; $FRAME_OPTIONS->contentCSSClasses []= 'content-fullheight';

View File

@ -8,6 +8,7 @@ require_once (__DIR__ . '/../internals/website.php');
<?php <?php
$FRAME_OPTIONS->title = 'Error'; $FRAME_OPTIONS->title = 'Error';
$FRAME_OPTIONS->statuscode = 404;
$FRAME_OPTIONS->canonical_url = null; $FRAME_OPTIONS->canonical_url = null;
$FRAME_OPTIONS->activeHeader = null; $FRAME_OPTIONS->activeHeader = null;
$FRAME_OPTIONS->contentCSSClasses []= 'content-fullheight'; $FRAME_OPTIONS->contentCSSClasses []= 'content-fullheight';