Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Nie mogę utwożyc ciasteczka
-slaveman-
post 14.06.2006, 19:03:00
Post #1





Goście







witam jak w temacie napisałem skrypt logowania powinien on po wpisaniu odpowiedzniego hasła utwożyć ciastko lecz nie robi tego tylko wyzuca mi taki błąd
  1. <?php
  2. Warning: Cannot modify header information - headers already sent by (output started at /home2/paulaxx/public_html/login.php:8) in /home2/paulaxx/public_html/login.php on line 9
  3. ?>


A o to cały skrypt

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="pl" lang="pl">
  3.  <head>
  4.  <title>Kurs php [www.kursphp.rar.pl]- Panel Administracyjny</title>
  5.  <link rel="stylesheet" href="style.css" type="text/css" media="all" />
  6.  </head>
  7.  <body> 
  8. <? If ($_POST['pass'] == 'haslo_haslo') {
  9. setcookie('password', 'true', time()+3600);
  10. echo('<div align="center"><div class="login">Jesteś zalogowany na 3 godziny<br />
  11. <a href="index.php">Wejdz do panelu</a></div></div>');
  12. }
  13. else {
  14. ?>
  15. <div align="center"><div class="login">
  16. <form action="login.php" method="POST">
  17. HASŁO:<input type="password" name="pass" size=20 />
  18. <input type="submit" value="zaloguj" />
  19. </form>
  20. </div></div>
  21. <? } ?>
  22. </body>
  23. </html>


Bardzo prosze o pomoc bo przewertowałem manuala i wszystkei możliwe kury a swojego błędu nadal nie widzię
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 24.07.2025 - 18:31