1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Fixed New YouTube URLs don't parse for embedding. The specified URL cannot be embedded as media.

Discussion in 'Resolved Bug Reports' started by Digital Doctor, Oct 19, 2011.

  1. Digital Doctor

    Digital Doctor Well-Known Member

    YouTube has changed their URLs recently.
    This URL
    Code:
    http://www.youtube.com/watch?feature=player_embedded&v=T8fsvYd2RBY
    results in an error:
    The specified URL cannot be embedded as media.
    Removing the text: feature=player_embedded&
    from the URL results in an embeddable video.
    results in an embedable video.
    Code:
    http://www.youtube.com/watch?[B][/B]v=T8fsvYd2RBY

    I got this URL from http://googleblog.blogspot.com/ (posted Oct 13, 2011).
     
    erich37 likes this.
  2. Brogan

    Brogan XenForo Moderator Staff Member

    I'm not sure this can be classed as a bug.

    Just add a new Match URL to the YouTube media BB Code.

    Code:
    youtube.com/watch?feature=player_embedded&v={$id}
     
    Abracadaniel, Dodgeboard and DSF like this.
  3. Digital Doctor

    Digital Doctor Well-Known Member

    Excellent point !

    Admins and Mods are going to be annoyed with questions regarding this issue from their users.
    The URLs just changed. Expect more and more reports of this !
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    Not much can be done when it is third party sites/software which change, other than for site administrators to try and keep up.
     
  5. Digital Doctor

    Digital Doctor Well-Known Member

    Other than fix it for beta4.
     
  6. Brogan

    Brogan XenForo Moderator Staff Member

    I certainly don't want my existing media BB Code settings being overwritten during an upgrade, so it would only be "fixed" for new installations.
     
    DSF and Daracon like this.
  7. Floris

    Floris Guest

    So every time jquery, google maps, whatismyip, twitter, facebook, addthis, youtube, vimeo, etc updates. We can assume that XenForo won't be updated to reflect these changes?

    That's just pathetic. Plain and simple. Sorry if that's rude.
    Auto embedding of youtube is a core feature, any customization on top of it is just like customizing templates.
     
  8. Brogan

    Brogan XenForo Moderator Staff Member

    The match URLs are stored in xf_bb_code_media_site:match_urls

    How does an upgrade take account of what's already in that field and merge it with any new or changed entries, which may or may not already be there, or may have been changed from the defaults?

    It's no different to the smilies changing to sprites in 1.1; any existing installations weren't affected but new installations use the sprite method.
     
  9. Digital Doctor

    Digital Doctor Well-Known Member

    This is an easy problem to fix.
    I would be surprised if it wasn't fixed in beta4.
     
    erich37 likes this.
  10. Kier

    Kier XenForo Developer Staff Member

    Fixed. No attitude required.
     
    erich37 likes this.

  11. Er, how is it fixed? I tried embedding a YouTube video using the "Media" in the forum, and got the exact same message, "The specified URL cannot be embedded as Media".

    Is there something I need to do additionally so that my members can embed YouTube videos, or others, for that matter?

    I copy/pasted the entire link, than just tried with the YouTube ID for that vid, and got the same message both times.

    Once I copy/pasted Brogan's fix, "youtube.com/watch?feature=player_embedded&v={$id}"
    and than added the YouTube ID between the { } the video did indeed embed, though I had to erase everything before the bracket so that nothing but the video showed up in the post. The end result was "[media =youtube]ID[/media]". Why does it not turn up like that from just c/ping the link, instead of having to do what I described previously?
     
  12. Brogan

    Brogan XenForo Moderator Staff Member

    It does.

    Which URL are you trying to embed?
     
  13. This one... http://www.youtube.com/embed/Q9dqjaTs780?rel=0

    After c/ping it in the "Media" address bar, I got "The specified URL cannot be embedded as Media".

    I tried several different variations of that link also.....I took out the embed, tried just pasting the ID number, all to no avail...same message every time.
     
  14. Brogan

    Brogan XenForo Moderator Staff Member

    Add this to the YouTube BB Code Media Site entry.

    Code:
    youtube.com/embed/{$id}
     
    Carl likes this.
  15. Awesome!! That fixed it! Thanks much Brogan, and thanks for the VERY quick response!
     

Share This Page