this may seem strange but you have to rememeber that header affects the client not the server script ( in fact it will continue to be executed if you dont stop it)
of course you can let the script continue but someone forget this behaviour and get "strange errors"
If you want to issue die on a file that is inside an include, it will keep everything else from running through and finishing.
You can prevent this by using return;. It ends the current file but lets the others keep going.
Perhaps the Coldfusion query below can be answered as follows:
---------
(From the "User Contributed Notes" for the PHP construct "exit")
nospam at mydomain dot com
27-Sep-2004 10:12
Using return instead of exit is to prefer when you want the script that you have included inside another script to die but continue to execute the main script.
// Radcliff
---------
To get a perl-like die you can/should append this snipped
. " File: " . __FILE__ . " on line: " . __LINE__
e.g.
die ("Error" . " File: " . __FILE__ . " on line: " . __LINE__);
Note that using the die() function will stop the entire script after that point from being run, so if you issue the die function within a open HTML tag, the HTML tag will remain open, which can seriously effect the browsers output to the user, expecially if its used inside an open <TABLE> tag.