Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP] Undefined index
TheBill
post 28.04.2014, 21:20:44
Post #1





Grupa: Zarejestrowani
Postów: 14
Pomógł: 0
Dołączył: 28.04.2014

Ostrzeżenie: (0%)
-----


Witam
Na wstępie chciałbym zaznaczyć, że żaden ze mnie programista.
Także proszę wszystko bardzo "łopatologicznie"

Na chwilę obecną mam problem z dobraniem się do pewnych danych:

  1. $summoner = $nicknamelist;
  2. $url = "http://prod.api.pvp.net/api/lol/eune/v1.4/summoner/by-name/" . $summoner . "?api_key=" . $key;
  3. $JSON = file_get_contents($url);
  4. $data = json_decode($JSON, true);
  5. $summonerId=$data["id"];
  6. //var_dump($data); <a href="http://pastebin.com/fNqK2K86" target="_blank">http://pastebin.com/fNqK2K86</a>
  7. // print_r($data); <a href="http://pastebin.com/qg3iXDNX" target="_blank">http://pastebin.com/qg3iXDNX</a>
  8. $urlLeague = "http://prod.api.pvp.net/api/lol/na/v2.3/league/by-summoner/" . $summonerId . "?api_key=" . $key;
  9. $JSONLeague = file_get_contents($urlLeague);
  10. $lgData=json_decode($JSONLeague,true);
  11.  

Wyskakuje mi powiadomienie
PHP Notice: Undefined index: id
Powiedzcie mi proszę co robię źle?

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: 14.08.2025 - 02:25