StarryGuy1980 Posted June 12, 2013 Share Posted June 12, 2013 I have seen the header("Location: http://example.com") takes some time to reach the browser but in the meantime the php script (if there is code after the header statement) continues to execute. So I recently started putting a die() immediately following the header() statement. I want to know if this a good practice? Do any of you experienced guys already do this? Quote Link to comment https://forums.phpfreaks.com/topic/279090-putting-a-die-after-headerlocation/ Share on other sites More sharing options...
kicken Posted June 12, 2013 Share Posted June 12, 2013 I want to know if this a good practice? Do any of you experienced guys already do this? Yes, see this post for some details on why. Quote Link to comment https://forums.phpfreaks.com/topic/279090-putting-a-die-after-headerlocation/#findComment-1435616 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.