From: Marcel Werk Date: Wed, 13 Jul 2016 14:24:40 +0000 (+0200) Subject: Improved error pages / messages X-Git-Tag: 3.0.0_Beta_1~1164 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=58f35d422d6498854533ba5ef0d81f031c4a4b15;p=GitHub%2FWoltLab%2FWCF.git Improved error pages / messages --- diff --git a/com.woltlab.wcf/templates/permissionDenied.tpl b/com.woltlab.wcf/templates/permissionDenied.tpl index 3146e91766..827bd56f28 100644 --- a/com.woltlab.wcf/templates/permissionDenied.tpl +++ b/com.woltlab.wcf/templates/permissionDenied.tpl @@ -1,8 +1,11 @@ {capture assign='pageTitle'}{lang}wcf.global.error.permissionDenied.title{/lang}{/capture} +{capture assign='contentTitle'}{lang}wcf.global.error.permissionDenied.title{/lang}{/capture} -{include file='header' __disableAds=true __disableContentHeader=true} +{include file='header' __disableAds=true} -

{lang}wcf.global.error.permissionDenied{/lang}

+
+

{lang}wcf.global.error.permissionDenied{/lang}

+
{event name='content'} diff --git a/com.woltlab.wcf/templates/userException.tpl b/com.woltlab.wcf/templates/userException.tpl index 66b2f430e5..9cbf3959f2 100644 --- a/com.woltlab.wcf/templates/userException.tpl +++ b/com.woltlab.wcf/templates/userException.tpl @@ -1,14 +1,23 @@ -{capture assign='pageTitle'}{lang}wcf.global.error.title{/lang}{/capture} +{if !$title|empty} + {capture assign='pageTitle'}{$title}{/capture} + {capture assign='contentTitle'}{$title}{/capture} +{else} + {capture assign='pageTitle'}{lang}wcf.global.error.title{/lang}{/capture} + {capture assign='contentTitle'}{lang}wcf.global.error.title{/lang}{/capture} +{/if} + +{include file='header' __disableAds=true} + +
+

+ {@$message} +

+
-{include file='header' __disableAds=true __disableContentHeader=true} - -

- {@$message} -

diff --git a/wcfsetup/install/files/lib/system/exception/IllegalLinkException.class.php b/wcfsetup/install/files/lib/system/exception/IllegalLinkException.class.php index dfc7bafe76..3824cb45b6 100644 --- a/wcfsetup/install/files/lib/system/exception/IllegalLinkException.class.php +++ b/wcfsetup/install/files/lib/system/exception/IllegalLinkException.class.php @@ -23,6 +23,11 @@ class IllegalLinkException extends NamedUserException { */ public function show() { @header('HTTP/1.0 404 Not Found'); + + WCF::getTPL()->assign([ + 'title' => WCF::getLanguage()->get('wcf.global.error.illegalLink.title') + ]); + parent::show(); } } diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index 059f9246ef..e33cf030d3 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -2354,7 +2354,7 @@ Fehler sind beispielsweise: - + Was ist passiert?

@@ -2400,7 +2400,8 @@ Fehler sind beispielsweise: - + + diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 3eabf5caac..8c643df697 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -2332,7 +2332,8 @@ Errors are: - + + What happened?

@@ -2378,7 +2379,8 @@ Errors are: - + +