Pomoc - Szukaj - Użytkownicy - Kalendarz
Pełna wersja: [PHP]błedy w kodzie az tyle
Forum PHP.pl > Forum > Przedszkole
miki23
Mam pytanie czemu przy tym kodzie mam az tyle błedów
  1. <?php
  2. $d=date('j');
  3. $m=date('n');
  4. $r=date('Y');
  5. $dt=date('w');
  6. $s='<p>Dziś jest ';
  7. switch ($dt) {
  8. case 0: { $s.='niedziela'; break; }
  9. case 1: { $s.='poniedziałek'; break; }
  10. case 2: { $s.='wtorek'; break; }
  11. case 3: { $s.='środa'; break; }
  12. case 4: { $s.='czwartek'; break; }
  13. case 5: { $s.='piątek'; break; }
  14. case 6: { $s.='sobota'; break; }
  15. default: $s='błąd';
  16. }
  17. $s.=", $d ";
  18. switch ($m) {
  19. case 1: { $s.='stycznia'; break; }
  20. case 2: { $s.='lutego'; break; }
  21. case 3: { $s.='marca'; break; }
  22. case 4: { $s.='kwietnia'; break; }
  23. case 5: { $s.='maja'; break; }
  24. case 6: { $s.='czerwca'; break; }
  25. case 7: { $s.='lipca'; break; }
  26. case 8: { $s.='sierpnia'; break; }
  27. case 9: { $s.='września'; break; }
  28. case 10: { $s.='października'; break; }
  29. case 11: { $s.='listopada'; break; }
  30. case 12: { $s.='grudnia'; break; }
  31. default: $s='błąd';
  32. }
  33. $s.=" $r roku.</p>";
  34. echo $s;
  35. ?>


Błedy:
Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '1.0/no DST' instead in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\... on line 15 Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '1.0/no DST' instead in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\... on line 16 Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '1.0/no DST' instead in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\... on line 17 Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '1.0/no DST' instead in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\... on line 18
NEO.pl
Czy przeczytales komuniakt bledu? Bo masz wyraznie napisane o co chodzi. Jesli nie radzisz sobie z angielskim to czy sprobowales najpierw uzyc chocby translate.google.com?
To jest wersja lo-fi głównej zawartości. Aby zobaczyć pełną wersję z większą zawartością, obrazkami i formatowaniem proszę kliknij tutaj.
Invision Power Board © 2001-2025 Invision Power Services, Inc.