• I’m having an issue with the OEmbed functionality on a multisite running 3.5.1

    When I put a YouTube URL on its own line in the editor, it does not get converted to an embed. I only get the URL in a paragraph tag.

    However, if I do the same thing with my localhost copy of the site, it works fine. The localhost copy is running the same version of wordpress, same theme, same plugins, with the same users with same permissions, same documents (running a copy of the production database).

    Before people ask:

    • I’m using Text mode, not Visual mode. I do not switch between them.
    • I’m putting the YouTube URL on its own line with no other content, empty lines before and after
    • I believe it’s not a YouTube issue as it works on localhost. I see the oembed meta tags on the video page (here: https://youtu.be/z4nLtt3eoDI)
    • It shouldn’t matter, but my account is the Super Admin. Other users with other roles have the same issue.
    • It’s 3.5.1 so there’s no Settings > Media option to enable auto-embeds. This is a new site that’s always been v3.5.1
    • I see the same issue regardless of post type: posts, pages, or any custom post types

    Any thoughts?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    What version of PHP are you running?

    Bumping this as I’m having the same issue.
    oembed works fine on my local dev host WAMP Server but not on production web server.

    What are the PHP requirements of oembed? Does it require any particular extensions?

    Todd

    Thread Starter leereamsnyder

    (@leereamsnyder)

    I’ve scanned over the oembed class and it appears to make a wp_remote_get() request to the various embed providers.

    We’re still looking at our production machine, but my suspicion is that our firewall blocks the server from reaching, say, youtube.com to retrieve the oembed information.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    That would be very likely :/ What does it show instead? I used to have the same problem at my old job.

    I have the same issue. I disable the firewall on my server but still not embed. Did you find a solution to your issue?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    crm50cc – Please make your own post (and if you’re NOT using Multisite, put it in the normal How To/Troubleshooting section). After 5 months, it’s unlikely to be entirely the same.

    Tips for you to test:

    * Turn off all plugins
    * From the command line, try pinging the oembed hosts (like twitter and youtube)

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘OEmbed works on localhost, but not on live site’ is closed to new replies.