$_SESSION[\"some_value\"] = 4;
header(\"Location: another-file.php\");
$_SESSION[\"some_value\"] = 5;
what\'s the value of $_SESSION[\"some_v
Once you issue the header, you've started a race between your code and the webserver/browser. Generally, as soon as the browser receives the redirect, it'll close the connection that ran the script and start connecting to the new redirect URL. When the connection's closed, the web server will generally try to kill the script.
You might get lucky and be able to finish off anything else you wanted to do, or your might be unlucky and the script won't even be able to reach the next line after the header() call.
There is the ignore_user_abort() function, which should let your script continue regardless of the connection's status, though.