![]() |
![]() |
![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 11 Pomógł: 0 Dołączył: 6.07.2003 Skąd: ślask Ostrzeżenie: (0%) ![]() ![]() |
chce zrobic autoryzacje na stronie !!!
mam problem !! po wpisaniu przykladu z manuala : <html> <head> </head> <body> <?php function authenticate() { header( "WWW-Authenticate: Basic realm="Testowy system autoryzacji""); header( "HTTP/1.0 401 Unauthorized"); echo "Musisz podać poprawny login i hasło by wejść na tę stronęn"; exit; } if(!isset($PHP_AUTH_USER) || ($SeenBefore == 1 && !strcmp($OldAuth, $PHP_AUTH_USER)) ) { authenticate(); } else { echo "</p>Witaj: $PHP_AUTH_USER<br>"; echo "Poprzenio: $OldAuth"; echo "<form action="$PHP_SELF" METHOD=POST>n"; echo "<input type="hidden" name="SeenBefore" value="1">n"; echo "<input type="hidden" name="OldAuth" value="$PHP_AUTH_USER">n"; echo "<input type="submit" value="Re Authenticate">n"; echo "</form></p>n"; } ?> </body> </html> wystepuje taki blad w : Warning: Cannot add header information - headers already sent by (output started at c:apachehtdocsuwierzytelnianie.php:5) in c:apachehtdocsuwierzytelnianie.php on line 7 Warning: Cannot add header information - headers already sent by (output started at c:apachehtdocsuwierzytelnianie.php:5) in c:apachehtdocsuwierzytelnianie.php on line 8 |
|
|
![]() ![]() |
![]() |
Aktualny czas: 19.08.2025 - 07:05 |