Posted by Zoe Brown on 10/10/05 19:17
"maisam" <maisamPOISTA@luukku.com.invalid> wrote in message
news:434a90e9$0$26817$9b536df3@news.fv.fi...
> Zoe Brown wrote:
>> "JDS" <jeffrey@example.invalid> wrote in message
>> news:pan.2005.10.10.15.55.03.894107@example.invalid...
>>
>>>On Mon, 10 Oct 2005 15:22:32 +0000, Zoe Brown wrote:
>>>
>>>
>>>>How do I do redirect a page to a new page in php ???
>>>
>>>Maybe you mean "header()"?
>>>
>>>http://us2.php.net/header
>>
>>
>> thanks.
>>
>> when I try this I get the error
>>
>> Warning: Cannot add header information - headers already sent by (...)
>
> As the error message puts it... headers are allready sent and you cannot
> add any. You have probably already printed out something or called
> ob_start, make sure you call the header() function before any such output
> statement.
>
argh !! I dont get it this is my entire script - what is wrong with it ?
<?php
$username="sggdfgfg";
$password="xgsdfgyz";
if (($_POST['username']==$username) && ($_POST['password']==$password)){
header("Location: main.html");
}
?>
Navigation:
[Reply to this message]
|