nimzie Posted October 29, 2007 Share Posted October 29, 2007 I have a page which is all PHP processing. It outputs errors via echo. Since I am using echos for errors, I can not use header("location:http://wwhatever.com") after the code to redirect to the HTML page depending on the success of my operation. The user arrives at this page after clicking a submit button. Form action gets me to the page. The page is all PHP right now. What is a good way to get around this? I do need the echos in case there are errors - also to keep the user apprised of what is happening in the processing. Any advice? Thanks, Adam Link to comment https://forums.phpfreaks.com/topic/75218-php-redirect-question/ Share on other sites More sharing options...
trq Posted October 29, 2007 Share Posted October 29, 2007 There is no point echoing anything prior to a redirect as it will not be shown. You need to adjust your logic accordingly. Link to comment https://forums.phpfreaks.com/topic/75218-php-redirect-question/#findComment-380428 Share on other sites More sharing options...
ThYGrEaTCoDeR201 Posted October 29, 2007 Share Posted October 29, 2007 header("refresh: 5; url=www.phpfreaks.com"); In this example, the page will be redirected in 5 seconds..This way the user can see the echo's of the errors before being redirected. Link to comment https://forums.phpfreaks.com/topic/75218-php-redirect-question/#findComment-380478 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.