Textpattern CMS support forum

You are not logged in. Register | Login | Help

#11 2016-04-28 20:11:55

johnno
Member
Registered: 2007-06-14
Posts: 27

Re: oui_instagram - Display Instagram user infos and recent images

Hmm…
Interesting results on an Instagram account with 41 images:

limit > 20 gives an error
limit = 21 shows first 20 then repeats first image
limit > 22 shows first 20 then repeats required number
limit > 33 shows first 20 then repeats required number
limit = 41 shows first 21 then repeats first image
limit = 42 shows first 22 then repeats first and second image
limit = 43 shows first 23 then repeats first, second image and third image
etc

Getting there!

Offline

#12 2016-04-28 20:26:13

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

johnno wrote #298873:

Hmm…

Ok, sorry, there is also a problem with the cache. It needs more work but I’ll get it.

Last edited by NicolasGraph (2016-04-28 22:11:24)


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#13 2016-04-30 10:47:22

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

oui_instagram v0.6.5 now supports Instagram pagination to pull more than 20/33 images.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#14 2016-05-12 16:08:43

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

Few enhancements are included in v0.6.6.
I recommend to remove the previous version before to install the new one because of a removed (hidden in fact) pref. If you do that keep your access token and others informations somewhere…


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#15 2016-05-13 16:48:26

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

v.0.6.7 has a better support for multiple galleries and a more reliable user id search.
As the default user id is now automatically filled in the prefs on saving, I recommend you to remove the last version one more time before to add this one.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#16 2016-05-23 11:42:42

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

You can now update to v0.6.8.
The plugin now uses the access token related account as the default account from which to pull images, so I removed the Default username and Default user id prefs. It should be the last changes in the prefs, please remove the previous version before to install v.0.6.8.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#17 2016-09-06 09:31:13

peterj
Member
From: Melbourne, Australia
Registered: 2005-06-02
Posts: 29

Re: oui_instagram - Display Instagram user infos and recent images

Thanks for this plugin, it is working swell.

Couple of items that may interest you – or may not.

I made a small hack around line 161 to allow a user to put their own access token into a custom field for their profile page, by making a new attribute access_token:

add

'access_token'   => '',

to attrs array, and wrap a conditional around the existing code retrieving the token:

	if (!$access_token) {
    	$access_token = get_pref('oui_instagram_access_token');
	}

then use this to display images from different accounts:

<txp:oui_instagram_images access_token='<txp:custom_field name="Instagram_token"/>' etc...

Also I couldn’t figure out why my specified default thumb size (standard res) in oui_instagram_images was delivering the small 150 thumbs – perhaps it isn’t clear that the default thumb size for txp:oui_instagram_image (the small one) overrides anything set in the container tag.

<txp:oui_instagram_image type="standard_resolution"/>

Thanks again, Peter.

Offline

#18 2016-09-06 14:15:30

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

peterj wrote #301106:

Thanks for this plugin, it is working swell.

Glad it helps!

I made a small hack around line 161 to allow a user to put their own access token into a custom field for their profile page, by making a new attribute access_token:

In fact you should be able to display different user galleries with only one Instagram access token by using the username or the user_id attributes; you can add 10 users in the sandbox mode or need to register your app to obtain a public_content permission.

However, if you find the Instagram registration too restrictive I could probably add this little hack in the next version; it would probably help in some cases.

Also I couldn’t figure out why my specified default thumb size (standard res) in oui_instagram_images was delivering the small 150 thumbs – perhaps it isn’t clear that the default thumb size for txp:oui_instagram_image (the small one) overrides anything set in the container tag.

You’re right, it is not clear, I will try to add that somewhere in the help file; thanks.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#19 2016-12-13 08:23:45

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

oui_instagram v1.0.0-beta is ready to be tried by you!
Be careful, the cache feature was removed from the plugin code and it is now recomended to use a caching system such as aks_cache to avoid too many external queries.


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

#20 2017-01-09 09:05:42

NicolasGraph
Plugin Author
From: France
Registered: 2008-07-24
Posts: 860
Website

Re: oui_instagram - Display Instagram user infos and recent images

oui_instagram is going to be officially released in its last version; few feedbacks more?


Nicolas
Follow me on Twitter and GitHub!
Multiple edits are usually to correct my frenglish…

Offline

Board footer

Powered by FluxBB