WoWCenter.pl
wikass zabił Mythrax the Unraveler (Normal Uldir) po raz 2.     
kuturin zdobył 7th Legionnaire's Cuffs.     
Nikandra spełnił kryterium Loot 200,000 gold osiągnięcia Got My Mind On My Money.     
Tooly zdobył Fairweather Helm.     
Muattin zdobył osiągnięcie The Dirty Five.     
Yoozku zdobył Parrotfeather Cloak.     
Mlody89 zdobył Royal Apothecary Drape.     
Weakness zabił Dazar, The First King (Mythic King's Rest) po raz 6.     
liq spełnił kryterium osiągnięcia Saving for a Rainy Day.     
Osiol spełnił kryterium osiągnięcia Saving for a Rainy Day.     
Wuntu zabił Zek'voz, Herald of N'zoth (Heroic Uldir) po raz 1.     
Olsa zabił Vectis (Heroic Uldir) po raz 6.     
Sarenus spełnił kryterium osiągnięcia Saving for a Rainy Day.     
kajtasus zdobył osiągnięcie Come Sail Away.     
ossir spełnił kryterium osiągnięcia Saving for a Rainy Day.     
mcpablo spełnił kryterium Alliance players slain. osiągnięcia Frontline Slayer.     
Emmm zabił Taloc (Heroic Uldir) po raz 17.     
AsaGorth spełnił kryterium Big-Mouth Clam osiągnięcia The Oceanographer.     

Searching the massive achievments array

blizz -> wysłany:
I was hoping someone might be so kind as to point me in the right direction, or share with me their solution to searching the massive array we get from here: http://us.battle.net/api/wow/data/character/achievements for a given achievement ID.

Other threads on this:
http://stackoverflow.com/questions/16783278/php-search-massive-array-for-value-return-parent-key


Sofar ive started breaking down the original array into its 10 categories and I was then going to search each one of those arrays until I found the ID i was looking for, but i feel as if there must be an easier way.

ex of what I have sofar:

$allAchieves = file_get_contents('http://us.battle.net/api/wow/data/character/achievements');
$allAchieves = json_decode($allAchieves, true);

$generalAchieves = $allAchieves[achievements][0][achievements];
$quests = $allAchieves[achievements][1][categories];
$explorationAchieves = $allAchieves[achievements][2][categories];
$pvp = $allAchieves[achievements][3][categories];
$dungeonAndRaids = $allAchieves[achievements][4][categories];
$professions = $allAchieves[achievements][5][categories];
$reputation = $allAchieves[achievements][6][categories];
$scenarios = $allAchieves[achievements][7][categories];
$worldEvents = $allAchieves[achievements][8][categories];
$petbattle = $allAchieves[achievements][9][categories];
$featsOfStrength = $allAchieves[achievements][10][categories];


As always, thanks for any help / guidance / or input!
blizz -> wysłany:
Would people want achievements changed to be in a different format instead of the giant id lists? I know this would cause a bunch of code to be rewritten if we made the change now.

If we were to add public statistics would we want to add it identical to the achievement list or should we go with a new format?
blizz -> wysłany:
Billymayys:
As for Statistics, What exactly does that refer to?

If you are talking about something that would read like:

HK's this week: #
Raid Bosses Killed This Week: #
LFR's Completed This Week: #
etc...
etc...

Or something to that effect, then that would be Absolutely Amazing.


It would be the data that's on your in game and web profile:
http://us.battle.net/wow/en/character/magtheridon/Billymayys/statistic