Redirect to custom error page if there is error in the page
问题 I am new to PHP web development. I want to know is there any code in PHP that redirects me to a page( let's name it "myerrorpage.php" ) if there is some error on the page? In JSP it's possible using the following code <%@ page errorPage="myerrorpage.jsp" %> I want to know is there any above JSP type of code in PHP?is yes then please help Any help is appreciated... 回答1: In php you don't redirect when there is an error in the code, you simply catch that error and then you take whatever actions