![]() |
Error page in production (CI 3) - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: Installation & Setup (https://forum.codeigniter.com/forumdisplay.php?fid=9) +--- Thread: Error page in production (CI 3) (/showthread.php?tid=91214) |
Error page in production (CI 3) - nico - 07-04-2024 Hello, Actually, in production mode, an error will send blank page to user. Is it possible to send a fixed error html page (blank page is ambigous for users), just to say there is an error ? In advance, thank you. RE: Error page in production (CI 3) - nico - 07-04-2024 I found a temp solution but I don't like it because I modified a file in system directory : system/core/Common.php : PHP Code: function _exception_handler($exception) RE: Error page in production (CI 3) - captain-sensible - 07-04-2024 for use of a "contact us" form the submitted data gets handled in a controller leveraging PHPMailer . I just use a view called info2.php which as : [CODE} <?php echo $info;?> <?php echo $infoException;?> [/CODE] I want simple error output if the message doesnt get sent. In the controller I have Code: try So if error is caught i call the view info2.php and pass data to it im using my gmail to rely out email , when the user name or password is not right as an example the following is output [CODE} something went wrong with sending message SMTP Error: Could not authenticate. [/CODE] that happened recently ..on a live web in production mode ; key words " could not authenticate" was enough info for me to check user and pass creentials . with i guess judicious use of try catch in controllers ,you msy be able to set things up for every evenuality |