1

I am coding up a simple Wordpress theme and I would like to embed Instagram images via shortcode as described on Wordpress.com and Instagram.com. (Both links point to the very pages that demonstrate how this should be working).

So either http://instagram.com/p/bNd86MSFv6/or [instagram url=http://instagram.com/p/bNd86MSFv6/ hidecaption=true width=320] should be OK to embed an image from Instagram.

However, they don't embed anything. Youtube and Vimeo work fine, but not Instagram. The URL just gets wrapped in a <p> tag. The page about oEmbed on Wordpress says, this should be supported since 3.5, I currently have WP 4.0 installed on my localhost.

What am I missing?

3

The main problem here is WordPress COM and ORG are NOT equal. Questions about support for the former are actually off-topic on WordPress Development.

One consequence of the non-equality of com and org is that the latter has no shortcode [instagram], so naturally it won't work - the built-in shortcodes can be seen at this list. On the other hand, you are right, according to the codex page about embeds Instagram is supported. Normally it works like this:

Instagram photo below

http://instagram.com/p/bNd86MSFv6/

Instagram photo above

It is important that the embeds link is on a separate line.

If that is not working for you, then you can try using the [embed] shortcode:

[embed]http://instagram.com/p/bNd86MSFv6/[/embed]

BTW tested the Instagram embed on a old WP 4.0 installation, it works just fine for me.

  • Thank you, I knew com and org are different, but I have secretly hoped that shortcodes would work on both 'editions', because the oEmbed page lists Instagram since v. 3.5. – Drunken Master Jun 15 '15 at 16:15
  • 1
    Sure, the hope dies last, I guess. That said, you can always create your own custom shortcode, in case you need some extra functionality, in addition to the standard embed feature. @DrunkenMaster – Nicolai Jun 15 '15 at 17:33

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.