Pomoc - Szukaj - Użytkownicy - Kalendarz
Pełna wersja: Pobieranie statusu GG a Internal Server Error
Forum PHP.pl > Forum > PHP
iker
Mam taki kod na sprawdzanie statusu GG.

  1. <?php
  2. function statusGG($number, $name){
  3. $file = fopen ("http://www.gadu-gadu.pl/users/status.asp?id=".$number."&amp;styl=2", "r");
  4. $status = fgets($file, 2);
  5. if ($status){
  6. return '<a href="gg:'.$number.'" style="background:url('template/images/gg/'.$status.'.png') no-repeat;padding:0px 0px 0px 20px;">'.$name.'</a><br />';
  7. } else {
  8. return '<img src="template/images/gg/1.png" />&nbsp;&nbsp;<a href="gg:'.$number.'">'.$name.'</a>';
  9. }
  10. }
  11.  
  12. echo statusGG('5284094', 'Tomek');
  13. ?>


Po wstawieniu go na localhoscie wywala mi Internal Server Error - 500. W php.ini allow_url_fopen = On więc powinno działać.

Co jest nie tak? Kod jest oczywiście Ok, działa na innym serwerze.
slash12345
Błąd w konfiguracji serwera. Ktoś musiał bawić się php.ini...
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.