Today I started working with the Instagram API. I got it working only with one problem.
Here is the code that I use:
$value = file_get_contents('https://api.instagram.com/v1/users/self/feed?access_token=mytokenhere');
$value = json_decode($value, true);
print_r($value)
My problem is that I want to get exactly 20 results yet I only manage to get exactly 16 of them. I tried a few things:
- The count parameter &count=20
- Checked if all the people on my feed aren't private
- Added a picture to Instagram, stays at 16.
I have no idea how I can fix this. When I say &count=5 it returns 4 and &count=10 gives 8..
Thanks in advance! Tips / help would be appreciated!
Edit: While reading this post through again I saw this: Count 5 returns 4 Count 10 returns 8 Count 15 returns 12 Count 20 returns 16 .. For every 5 it just leaves one out. I just tried 25 and it worked! I got returned with 20.
Still I think this is a problem! Or is this how it is supposed to work?