Make WordPress Core

Opened 17 years ago

Closed 16 years ago

Last modified 12 years ago

#11556 closed enhancement (fixed)

Add support for embedding YouTu.be URLs

Reported by: Viper007Bond Owned by:
Priority: normal Milestone: 3.0
Component: Embeds Version: 2.9
Severity: normal Keywords: has-patch tested
Cc: Focuses:

Description

http://youtube-global.blogspot.com/2009/12/make-way-for-youtube-links.html

Allows you to embed them. Needs to be transformed internally as their oEmbed provider doesn't support them. Adds a new filter to do it.

Attachments (2)

11556.patch (1.3 KB ) - added by Viper007Bond 17 years ago.
11556.2.patch (962 bytes ) - added by Viper007Bond 16 years ago.
Whitelist youtu.be

Download all attachments as: .zip

Change History (13)

@Viper007Bond
17 years ago

#1 @hakre
17 years ago

  • Keywords needs-testing added

#2 @nacin
17 years ago

  • Keywords tested added; needs-testing removed

#3 follow-up: @westi
17 years ago

  • Keywords reporter-feedback added

Could we not just register youtu.be as another oembed provided and rely on the 302 following of the HTTP handlers.

That way we don't need any youtu.be specific code in here and if they change the url format of any of the providers in future and offer 302 redirects we would follow those too?

#4 in reply to: ↑ 3 @Viper007Bond
17 years ago

Replying to westi:

Could we not just register youtu.be as another oembed provided and rely on the 302 following of the HTTP handlers.

That way we don't need any youtu.be specific code in here and if they change the url format of any of the providers in future and offer 302 redirects we would follow those too?

No, because their oEmbed provider doesn't understand their shortened URLs.

Example short URL: http://youtu.be/nTDNLUzjkpg

Their provider returns a 401 for that URL: http://www.youtube.com/oembed?format=xml&url=http%3A%2F%2Fyoutu.be%2FnTDNLUzjkpg

Ideally their oEmbed provider should support their short URLs. I didn't think that'd be possible, however I recently saw one of the YouTube people post to the oEmbed mailing list, so I'll see if I can get them to support their short URLs so we can just map them directly to their oEmbed provider.

#5 @ryan
17 years ago

  • Component GeneraloEmbed

#6 @nacin
16 years ago

  • Milestone 3.0
  • Resolutionworksforme
  • Status newclosed

YouTube's oEmbed provider now understands shortened URLs.

#7 @Viper007Bond
16 years ago

Sweet. :)

#8 follow-up: @Viper007Bond
16 years ago

  • Resolution worksforme
  • Status closedreopened

Actually, we still need to add that format to the whitelist, we just don't need a remapping function.

#9 in reply to: ↑ 8 @nacin
16 years ago

Replying to Viper007Bond:

Actually, we still need to add that format to the whitelist, we just don't need a remapping function.

Oops, yep.

@Viper007Bond
16 years ago

Whitelist youtu.be

#10 @automattor
16 years ago

  • Resolutionfixed
  • Status reopenedclosed

(In [13203]) Add Youtu.be short URLs and Smugmug to the default oEmbed providers. Props Viper007Bond, fixes #11556, fixes #12157

#11 @DrewAPicture
12 years ago

  • Keywords reporter-feedback removed
  • Milestone3.0
Note: See TracTickets for help on using tickets.