Hello, I am new to the forums so bear with me.
I am trying to do a simple re-direct using the header function with php4.
Here is the situation. I do all of my coding on WinXP pro using IIS 5.
I then upload my files to my web server using Apache (not sure what version).
Anyways, I have been building a cookie based login system for my website and have been using the header function for my redirects.
I am using this format on my local computer.
header("Location: [url]http://[/url]" . $SERVER['HTTP_HOST'] . dirname($SERVER['PHP_SELF']) . "/index.php");
This works like a charm on my local computer (IIS) but when I upload to my webserver I end up with 2 forward slashes in my URLs.
So it looks like this http://mysite//index.php.
This is leading to some errors that I do not experience on localhost.
I am just wondering if there is an apache setting or configuration that is causing this?
Of if I am faced with just hard coding URL's??? Which won't work on both so I will have to write 2 sets of code which I don't want to nor feel I should have to do???
Any help on this matter would be appreciated!