Hurme Posted February 10, 2020 Share Posted February 10, 2020 Hello, pagefileSecure works wonders, but how can I catch the error message and replace it with something more human instead of the "Internal Server Error" that pops up? Best scenario for me, would be to redirect the user on another page instead. Link to comment Share on other sites More sharing options...
BitPoet Posted February 11, 2020 Share Posted February 11, 2020 21 hours ago, Hurme said: instead of the "Internal Server Error" that pops up "Internal Server Error" or "Page Not Found"? The latter is what you should be seeing for inaccessible files, and that's the correct thing for ProcessWire to do according to HTTP standards. If you see an internal server error (status code 5xx), something's wrong. For a "Page Not Found" error, PW renders the "404 Not Found" page under "Home" unless you have configured a different page as $config->http404PageID in site/config.php. You can create your own error page template and change to that in the page properties to adapt the output and make it more dynamic. 1 Link to comment Share on other sites More sharing options...
Hurme Posted February 12, 2020 Author Share Posted February 12, 2020 Internal Server Error. It only seems to happen when user tries to access files protected with PageFileSecure. Otherwise the 404 pages work normally. Link to comment Share on other sites More sharing options...
BitPoet Posted February 12, 2020 Share Posted February 12, 2020 That shouldn't happen, but you should be able to see what went wrong either in the http server's error log or in the PHP log. My first guess would the standard template's PHP code, but it could be a lot of things. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now