Can any body tell what wqrong i'm doing !
Posted: Sun May 04, 2003 1:41 am
hi ,
i'm checking for the username if it is "usama" then i'm simply redirecting it to login page but it's not working .... it simply prints the user name and warnings ...
the out put of the this php code is
......................OUT_PUT..............................................
usama
Warning: Cannot modify header information - headers already sent by (output started at G:\MS Publishers\Login_test.php:4) in G:\MS Publishers\Login_test.php on line 7
PHP Warning: Cannot modify header information - headers already sent by (output started at G:\MS Publishers\Login_test.php:4) in G:\MS Publishers\Login_test.php on line 7
//..............................................................................
here is the code ....
//////////////////////////////////////////////////////////////////
<?php
require 'functions.php';
echo($DB_LOGIN);
// Check whether the user is already authenticated or not
if($DB_LOGIN=="usama"){
header("Location: http://localhost/default.htm",false);
$DB_LOGIN="";
exit;
}
else if(!authenticateUser( $cookie_user, $cookie_passwd)){
header("Location:http://localhost/display.php");
exit();
}
?>
////////////
i'm using winxp with IIS 5
what is the wrong i'm doing ... Can any budy tell...
Noman.
i'm checking for the username if it is "usama" then i'm simply redirecting it to login page but it's not working .... it simply prints the user name and warnings ...
the out put of the this php code is
......................OUT_PUT..............................................
usama
Warning: Cannot modify header information - headers already sent by (output started at G:\MS Publishers\Login_test.php:4) in G:\MS Publishers\Login_test.php on line 7
PHP Warning: Cannot modify header information - headers already sent by (output started at G:\MS Publishers\Login_test.php:4) in G:\MS Publishers\Login_test.php on line 7
//..............................................................................
here is the code ....
//////////////////////////////////////////////////////////////////
<?php
require 'functions.php';
echo($DB_LOGIN);
// Check whether the user is already authenticated or not
if($DB_LOGIN=="usama"){
header("Location: http://localhost/default.htm",false);
$DB_LOGIN="";
exit;
}
else if(!authenticateUser( $cookie_user, $cookie_passwd)){
header("Location:http://localhost/display.php");
exit();
}
?>
////////////
i'm using winxp with IIS 5
what is the wrong i'm doing ... Can any budy tell...
Noman.