S Murder Posted May 7, 2007 Share Posted May 7, 2007 So, if at the top of the page I redirect the user with Javascript, will PHP output the whole file and send it to the client, or will the page be sent as its written, meaning only the part up to the point where it's redirected is written out and sent? Link to comment Share on other sites More sharing options...
Mr_CHISOL Posted May 7, 2007 Share Posted May 7, 2007 PHP will send the whole file, unless you tell it not to...Use exit(); after you output the javascript (in php) and it will stop executing. Link to comment Share on other sites More sharing options...
S Murder Posted May 7, 2007 Author Share Posted May 7, 2007 PHP will send the whole file, unless you tell it not to...Use exit(); after you output the javascript (in php) and it will stop executing.Will it cause everything after exit() to not be sent at all? Link to comment Share on other sites More sharing options...
justsomeguy Posted May 7, 2007 Share Posted May 7, 2007 The exit function stops all execution at that point. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.