Why are you using javascript to redirect?
Just use header('Location: http://somesite.com/page.html'); . You can use a relative url as well. Make sure you have nothing being echoed to the browser before calling that.
If you are still getting an internal server error, post more code because that function will not cause that.
kkeith29
Nearly a Posting Virtuoso
1,357 posts since Jun 2007
Reputation Points: 235
Solved Threads: 194
Why do you have break; in the function? You don't have a control structure that accepts that.
kkeith29
Nearly a Posting Virtuoso
1,357 posts since Jun 2007
Reputation Points: 235
Solved Threads: 194
Hi,
When you use a cable modem or a DSL connection to try to connect to a Microsoft Internet Information Services (IIS) site that is running on a Microsoft Windows 2000 Professional-based computer, you may receive the following error message in Microsoft Internet Explorer:
Error 500
If you click to clear the Show friendly HTTP error messages in the Internet Options dialog box in Internet Explorer, and then you try to connect to the same site over the same connection, you may receive one of the following messages in Internet Explorer:
Bad Url
Bad Gateway
Note To locate the Show friendly HTTP error messages check box, click Tools, click Internet Options, and then click the Advanced tab.
emarshah
Junior Poster in Training
61 posts since Jan 2008
Reputation Points: 10
Solved Threads: 6
Hi,
I get an error 500 when I try to open my web page with IE, but not with other Programs as Firefox or Safari. The problem I think is with the redirect in the index.php file, but I don't see the problem.
Here is the code:
<?
fcnX('home.php');
And the function is a Java script:
}
function fcnX($prUrl){
echo '<script language="javascript">' . "\n";
echo '<!--' . "\n";
echo 'document.location = \'' . $prUrl . '\';' . "\n";
echo '-->' . "\n";
echo '</script>' . "\n";
break;
exit;
}
Any ideas?
Thks!
Well perhaps you may need to specify the full url in the function instead of just a page name. Below is an example of how you should use your function:
<?
fcnX('http://www.example.com/blogs/home.php');
You may find that IE is just getting confused without the full address.
cwarn23
Occupation: Genius
3,033 posts since Sep 2007
Reputation Points: 413
Solved Threads: 259