redirect - PHP header('Location ... after include not working -


I try to redirect someone after a login. I have actually done a lot of this and now I have to face a strange problem.

I've created a very short test file to show the problem:

  & lt; Php session_start (); Include 'db.php'; Included 'sessionhelpers.inc.php'; Header ('location: ../login.php?e=x'); Go out(); ? & Gt;   

When I do not include db.php when I include it, it is not strange that I also engrossed the whole contents of the file db.php and It still does not work. Apart from this the file is usable because I use it on many other points of my code.

Any thoughts?

The only scenario that I can think of is that you have a BOM character in one of your files can read.
Open your files with your FTP client if any of these files have a strange character and remove it.


Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -