Theme the An unexpected error occurred page.
Permalink 1 user found helpful
Is there way to set this page to your custom theme? I came across this error page and can't for the life of me find out where to change this. It currently shows the concrete5 theme.
thanks for the quick reply ideasponge.
unfortunately that didn't work. i'm not sure what the page is called.
maybe this will help...
try to reach this page within your own concrete install.
www.www.yoursitehere.com/login/change_password...
You should get a missing argument error which is expected..however it should also read "Unexpected Error Occurred". That is the page I need to theme.
Reason being, is if a user doesn't follow their "Forgot Password" email link in time, that page errors out on them because the key becomes invalid. However I would think any page that serves that error message should be theme-able.
unfortunately that didn't work. i'm not sure what the page is called.
maybe this will help...
try to reach this page within your own concrete install.
www.www.yoursitehere.com/login/change_password...
You should get a missing argument error which is expected..however it should also read "Unexpected Error Occurred". That is the page I need to theme.
Reason being, is if a user doesn't follow their "Forgot Password" email link in time, that page errors out on them because the key becomes invalid. However I would think any page that serves that error message should be theme-able.
You should have a view.php in your /themes/theme-name/ folder.
Sometimes I just make a copy of the default.php.
But make sure you add this code within the view.php, to print the content of the single_pages:
Sometimes I just make a copy of the default.php.
But make sure you add this code within the view.php, to print the content of the single_pages:
<?php print $innerContent; ?>
ok this problem occurs before c5 has a chance to set what Theme is to be used so that is why you get the default core. However here is a fix.
Create a DIR named "core" in your Themes DIR. then create a file called "error.php".
Copy your view.php contents into it and make sure that the ONLY php you have in this page is
Put that in place of where you had the "print $innerContent;" code. Also make sure you don't have any other PHP in the head or anywhere else. also make sure the HTML is complete, not being broken up into multiple files that are normally included.
You will need to hardlink to your CSS and images instead of using the dynamic call that is usually used.
After you do that upload it to your server and when this error comes up it will use your desired look and feel.
Create a DIR named "core" in your Themes DIR. then create a file called "error.php".
Copy your view.php contents into it and make sure that the ONLY php you have in this page is
<?php Loader::element('error_fatal', array('innerContent' => $innerContent, 'titleContent' => $titleContent)); ?>
Put that in place of where you had the "print $innerContent;" code. Also make sure you don't have any other PHP in the head or anywhere else. also make sure the HTML is complete, not being broken up into multiple files that are normally included.
You will need to hardlink to your CSS and images instead of using the dynamic call that is usually used.
After you do that upload it to your server and when this error comes up it will use your desired look and feel.
That did the trick! Thanks for that ideasponge. Woot!
It would be something like this
$v->setThemeByPath('/user_error', "yourtheme");
I think that is the page but I could be wrong.
Make sure you uncomment the $v = View::getInstance(); line.
You can set any of your single pages to use your theme from this file and using this method.