Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#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: 110

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

#21 2017-01-13 12:11:15

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,565
Website GitHub Mastodon

Re: oui_instagram - Display Instagram user infos and recent images

Hi Nicolas,

Just testing this plugin out, thanks.

Spotted something I think – the class on the <txp:oui_instagram_images /> wrap tag doesn’t seem to be respected. I used class="image-tiles layout-container" but the code output is as follows: <ul class="Oui\Instagram\Main">.

For now I’ve worked round it by specifying wraptag="" and creating a wrap tag in HTML.

Overall, really like this plugin: here it is running on our company homepage

Offline

#22 2017-01-13 13:12:52

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

Re: oui_instagram - Display Instagram user infos and recent images

philwareham wrote #303559:

[…] Spotted something I think – the class on the <txp:oui_instagram_images /> wrap tag doesn’t seem to be respected…

Thanks for the feedback Phil, and sorry for this stupid mistake; you can download the second beta version on the release page of the plugin repo.

Edit: Thanks for the link; it’s nice to see the plugin in action!

Last edited by NicolasGraph (2017-01-13 13:22:56)


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

Offline

#23 2017-01-13 13:24:29

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,565
Website GitHub Mastodon

Re: oui_instagram - Display Instagram user infos and recent images

NicolasGraph wrote #303560:

Thanks for the feedback Phil, and sorry for this stupid mistake; you can download the second beta version on the release page of the plugin repo.

Great! Works as intended now.

Offline

#24 2017-01-18 10:14:23

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

Re: oui_instagram - Display Instagram user infos and recent images

oui_instagram users, feel free to show where and how you’re using the plugin.
Post your URL here if you’re ok to see it shared or just send it to me by email.
Thanks!


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

Offline

#25 2017-01-25 14:23:06

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

Re: oui_instagram - Display Instagram user infos and recent images

There’s a new beta version available online; it should be the last one and the final version should be out next week.

There are few improvements included in this release but you should mainly care about the fact that oui_instagram_ tags are now deprecated in favour of oui_insta_ shorter tags, that’s why these deprecated tags are not registered anymore and will throw a warning in debug mode.

Otherwise, I kept the same plugin and pref names for better consistency and easy update.


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

Offline

#26 2017-01-30 09:34:30

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

Re: oui_instagram - Display Instagram user infos and recent images

It’s time to update to v1.0.0!


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

Offline

#27 2019-04-25 18:14:08

zenman
Member
Registered: 2017-08-28
Posts: 41
Website

Re: oui_instagram - Display Instagram user infos and recent images

Thanks Nicolas for the plugin. It works fine.

Question is this: using <txp:oui_insta_image type=“thumbnail” /> I get very small thumbnails (160 × 160 px) whereas Instagram standart thumbnails are 320 × 320. Is there anyway I can change the resolution to improve thumbnails quality on my site?

Offline

#28 2019-04-25 20:35:02

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 5,205
Website GitHub

Re: oui_instagram - Display Instagram user infos and recent images

zenman wrote #317772:

Question: using <txp:oui_insta_image type=“thumbnail” /> I get very small thumbnails (160 × 160 px) whereas Instagram standart thumbnails are 320 × 320. Is there anyway I can change the resolution to improve thumbnails quality on my site?

Try using standard_resolution instead of thumbnail for the type attribute. See the help for oui_insta_images and our_insta_image.


TXP Builders – finely-crafted code, design and txp

Offline

#29 2019-04-26 03:06:27

zenman
Member
Registered: 2017-08-28
Posts: 41
Website

Re: oui_instagram - Display Instagram user infos and recent images

jakob wrote #317773:

Try using standard_resolution instead of thumbnail for the type attribute. See the help for oui_insta_images and our_insta_image.

yes, i see. but they are not always square. i am satisfied with type=“thumbnail” but need larger pics.

Offline

#30 2019-04-26 07:57:06

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 5,205
Website GitHub

Re: oui_instagram - Display Instagram user infos and recent images

zenman wrote #317774:

yes, i see. but they are not always square. i am satisfied with type=“thumbnail” but need larger pics.

Ah, that’s probably because not all the instagram shots are square. I’m not an instagram user, but from looking around, I see conflicting information. Some say you can get a cropped square image by modifying the url of the image, others say that no longer works. See, for example here and here (note: on medium). Some provide some code that could be patched into the plugin, but I’m not sure if those tips still work (the first of those posts, for example, has broken demo images).

What should work regardless is to use the large image size and then use CSS object-fit: cover; to constrain the large image cropped in a square container. More details and examples here. The main payoff is your motif may not always be in the centre of the crop.


TXP Builders – finely-crafted code, design and txp

Offline

Board footer

Powered by FluxBB