0

Trying to configure Media Entity Instagram, following https://drupal-media.gitbooks.io/drupal8-guide/content/modules/media_entity/instagram.html.

TL;DR:

I have an Instagram media entity getting its source from an instagram_link field. When I add an Instagram video URL to that field and set the field display to Link, I see the link. I want to display it as an Instagram Embed, but if I choose that display option, I don't get anything at all.

Long Version

Part of my problem is that the Instagram API is about to be deprecated, so all of the Drupal 7 and 8 modules that use the old API are unsupported. Another part of my problem is that Drupal core media has changed quite a few times between 8.0 and 8.8, so the documentation at drupal-media.gitbooks.io is out of date (though otherwise excellent) and there does not seem to be any newer version of the documentation yet.

I was able to configure Media Entity Twitter by following these instructions, but Instagram was much more difficult.

When I add a new media type at /admin/structure/media/add I am supposed to supply a Link field, but that field does not exist on the bundle.

If I just say "Create" then I get an Instagram field but after media type creation I cannot change the source field to a Link field.

As a workaround, I added a Link field to my Twitter bundle so it would be available at Instagram media entity type creation.

Finally, I have an Instagram media entity getting its source from an instagram_link field.

So far, sorta good ... when I add an Instagram post URL to that field and set the field display to "Instagram Embed" I see the post formatted nicely as expected.

However, Instagram videos do not work the same way. When I add an Instagram video URL to that field and set the field display to Link, I see the link.

If I set the field display to URL Embed, it will show the Instagram video, so I know the URL is valid.

Unfortunately I don't like the way URL Embed displays IG videos. I want to see it in a nice div with an image and caption, so I want to display it as an Instagram Embed. If I choose that display option, I don't get anything at all.

What am I missing? The issue queue for this module is full of people who seem to be able to use the media type.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.