the error is caused by a blank space after the closing php tag on line 4:
remove the blank space at the end of line 4.
to trouble shoot further, add the following after the <body> tag of the login page:
<pre><?php var_dump($_SESSION); ?></pre>
also double check that the server is capable of storing a sesion variable, use the session test page from the following thread: