![]() |
Standard Error Page
Is there some global function or check I can use to see if the current page is an error page? I have a custom right hand menu that I'd like to hide some stuff in when an error page is shown.
--------------- Added [DATE]1234391543[/DATE] at [TIME]1234391543[/TIME] --------------- I'd also like to know if the same can be found out about the standard redirect as well. |
Add plugins at error_generic and redirect_generic and create a variable that sets to true. Check this variable in your templates.
|
OK, have created a plugin at error_generic that has this simple bit of code....
PHP Code:
HTML Code:
<if condition="$hide_stuff != 'true'"> |
Make sure that the variable is in global scope, add the following line as 1st line of that plugin:
PHP Code:
|
Nope, still doesn't set any value. I must be missing something....
|
Which template are you putting your code in?
|
It's a custom template that gets included via a different plugin. Could that be the problem?
|
If the template is called before the variables are defined, it is not going to work.
|
So which gets called first? error_generic or parse_templates?
|
parse_templates
|
Turn debug mode on and you will see all the hooks that are called and in what order.
|
Quote:
Any other ideas? |
All times are GMT. The time now is 06:51 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|