#33072 closed enhancement (wontfix)
YouTube Embeds Not Supporting rel=0
Reported by: | jroy1082 | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 4.2.2 |
Component: | Embeds | Keywords: | needs-patch |
Focuses: | Cc: |
Description
YouTube embeds allow you to add rel=0 to the url to disable related videos at the end of the video. This doesn't appear to be working when trying to embed a video in WordPress. I believe this used to work judging by the number of articles and tutorials about it.
Change History (7)
#2
@
9 years ago
- Type changed from defect (bug) to enhancement
If you pass an URL like https://www.youtube.com/watch?v=BpAdyFdE3-c&rel=0
to YouTube's oEmbed API, it doesn't respect the rel
parameters.
All tutorials regarding this topic I could find rely on a plugin that just parses the oEmbed result to append the needed params.
That means this isn't really a bug in WordPress but a limit set by YouTube.
#3
@
9 years ago
In that case, we should work to do the same in core - so that users can still use the rel parameter without wondering why it isn't working.
#4
@
9 years ago
Related: #31920
There are many other providers who support different params too, for example Vimeo. Just limiting this to YouTube wouldn't be good.
But perhaps this is better off as being plugin territory. Filtering the output via regex could break many embeds if a provider changes it.
#5
follow-up:
↓ 6
@
9 years ago
In general, I'm against one-offs on our end that modify the response from a provider's oEmbed endpoint. It just makes for more things to go wrong if they change their output, as @swisspidy points out.
#31920 is an exception as that's a very common use case, but I'd argue this one is much less so.
I agree this is plugin territory (there's lots of great filters!) and closing this as wontfix
.
#6
in reply to:
↑ 5
@
9 years ago
- Milestone Awaiting Review deleted
- Resolution set to wontfix
- Status changed from new to closed
Replying to Viper007Bond:
I agree this is plugin territory (there's lots of great filters!) and closing this as
wontfix
.
Actually closing this as wontfix now :)
Confirmed. The visual editors auto-embed does not check for the ?rel=0 variable.
ex: https://www.youtube.com/watch?v=C0DPdy98e4c?rel=0