Needs review
Project:
Media: YouTube
Version:
7.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
8 Feb 2009 at 04:47 UTC
Updated:
5 May 2021 at 20:04 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
alex ua commentedThis would be a nice addition to the module, though I'm not really sure how it would best be implemented. I'm guessing the only way to do this would be to look for the #t= hash and pulling out the value. But- have you tried using the #t= in the embedded code? Does it still work?
Comment #2
andrewsuth commented+1
From: http://www.online-tech-tips.com/cool-websites/how-to-specify-a-starting-...
There's also an example of the final output of the object on the site. This method works for me just fine.
Comment #3
andrewsuth commentedComment #4
yannickoointeresting...
Comment #5
alex ua commentedYouTube is no longer supported directly in Emfield, moving to the Media_YouTube issue queue.
Comment #6
eiland commentedsubscribe
Comment #7
Pls commentedWhat has to be done to have this feature? I mean is this technically easy to implement or difficult? Thanks.
Comment #8
Bob Enyart commentedAs of June 30, 2012, for me, this is not working:
In the YouTube window, instead of the video streaming, I get this: "An error occurred. Please try again later."
I'm a user. I can't figure out what version of Drupal our site is running. (BTW, it's http://prolifeprofiles.com)
Help :)
Comment #9
yannickooIt's Drupal 6.25 (CHANGELOG.txt and the duplicate tag).
Comment #10
RobW commentedRight now only the 7.x versions are under active development. This looks like a pretty simple regex and formatter addition -- let's try and get it into 7.x-2.x, and then if anyone backports it in a patch for 6.x I'll commit it.
Comment #11
RobW commentedThe YouTube player parameter docs cover a
startparameter that doesn't seem to work anymore. Although it's undocumented, it looks like the current parameter ist=XXhXXmXXs.Comment #12
RobW commentedThere are a few ways I can see this working. The simplest would be to rewrite the regex in MediaInternetYouTubeHandler.inc to return the video id with the
tparameter, then use regex in theme.inc to split them up again, sincewmode=opaquehas to be the first query string parameter.Regex wizards welcome to offer regexes.
Comment #13
RobW commentedMarked #1273714: Respect timestamp in embed URL as duplicate.
Comment #14
lapith commentedHere is a pretty simple patch as a first attempt. As far as I can tell the end param is not supported directly through the browser (IE I can't add an end to a youtube link and have that work on their site, it only works on embeds).
For this to work simply append the t and end params to the youtube link. The t can be added automatically with the share button, the end will need to be added manually:
https://www.youtube.com/watch?v=[youtube_video]&t=[start_seconds]&end=[end_seconds]Comment #15
lapith commentedJust a quick change of a function name.
Comment #16
lapith commentedJust a quick change of a function name.
Comment #17
Funksmaname commentedAny chance of a port to 6 please? :*(
Comment #18
yannickooMissing space after "if".
Maximal 80 characters in a comment line.
Missing space after "//" and punctation mark.
Comment #19
Rob_Feature commentedJust an update here since I wanted to add this patch to the latest D7 version:
@youtu\.be/.+?\?t=([^"\& ]+)@I'Hope that at least helps send folks in the right direction...
Comment #20
brulain commentedHi,
Also needing YouTube time stamp : is #16 patch OK ?
Thanks
Comment #21
joseph.olstadRob_Feature, can you please roll up a new patch with your tweak, thanks!
to clarify, this is for the 7.x-2.x version?
or 7.x-3.x ?
Comment #22
cristianalcaraz commentedHi,
I've created a patch in order to work with new Youtube URL pattern as mentioned by @Rob_Feature.
Also added a condition to check the parameter ?t= with the new format XhYmZs.
Hope you find this useful :)
Comment #23
joseph.olstadthis is for 3.x right?
Comment #24
cristianalcaraz commentedYes @joseph.olstad :)
Sorry for the late reply!
Comment #25
cboyden commentedComment #26
jvdkolk commented#22 does not work for the following YouTube URL
https://www.youtube.com/embed/uEy_NGDfo_8?start=10&end=20
Comment #27
jvdkolk commentedComment #28
jvdkolk commentedI updated patch #22
Comment #29
solideogloria commentedThe added code does not follow Drupal coding standards.
Comment #30
solariel commentedHere's a cleaned version of #28 with somewhat unified regulars.
Comment #31
solariel commentedUpdated regulars to eliminate possible false positives and fixed warnings in the matchEmbedCode() method when partial time (ex. 1m2s) is passed.
Comment #32
joseph.olstadlatest patch failed to apply, needs a re-roll
Comment #33
cboyden commentedRe-rolled patch is attached.