I have configured and setup the youtube direct lite and deployed the app in the google app engine.I am able to submit videos and these videos are approved and a approval mail is successfully send.But when I am trying to embed the playlist code of the uploaded video,
<object width="480" height="385">
<param name="movie" value="http://www.youtube.com/p/PLwNZwNRcLsUoRtvyzHc3dYz1uLV_z9R2M? fs=1"></param>
<param name="allowFullScreen" value="true"></param>
<param name="allowscriptaccess" value="always"></param>
<embed src="http://www.youtube.com/p/PLwNZwNRcLsUoRtvyzHc3dYz1uLV_z9R2M?fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="385"></embed>
</object>
I am getting a white screen with no video shown.The video link that is generated also says the link is broken.But that is automatically generated link and it cant be broken.pls help
Based on what you describe, I believe you're using YouTube Direct, not YouTube Direct Lite. I'd recommend using the newer, more maintained YouTube Direct Lite at this point.
In any case, I just updated the code that gives out playlist embeds in YouTube Direct's admin interface to use the new iframe playlist player syntax, which should work better:
https://code.google.com/p/youtube-direct/source/detail?r=633
Try updating your YouTube Direct installation to pick up that new code, and regenerate your playlist embed code from the admin interface.
Related
I do live streaming with YouTube and I can watch it on my site by coping the embed code into my site
Its looks like this below
<iframe width="640" height="360" src="https://www.youtube.com/embed/gz54fede3Y" frameborder="0" allowfullscreen></iframe>
But recently I discovered that every time I do a live stream, I have to start updating the embeded code on my site each time with the one that will be generated from my live channel.
This is because it keeps regenerating a different code. Its so frustrating to do this, is there a way to get a particular embed code that will not change so I don't have to worry about this, or is there a setting that I am not aware of.
There is a static URL to embed the video player for the "Stream now" stream. It is currently not exposed anywhere in the UI, but we will fix that soon (hopefully.)
It looks like this: https://www.youtube.com/embed/live_stream?channel=[channel ID]
You can also use a YouTube Gaming link, like so: https://gaming.youtube.com/embed/live_stream?channel=[channel ID]
You can determine your channel ID by going to https://www.youtube.com/account_advanced and copying the string after "YouTube Channel ID".
Once you've got this link, you can use it in the "src" attribute of your embed code.
I need to play VEVO videos on an HTML5 player which is created using YouTube's API in iOS.
https://developers.google.com/youtube/iframe_api_reference
Currently I'm able to play normal videos with out a glitch.But when ever i try to play a VEVO video,It says "The content cant be played outside of YouTube".Is there any legal way of going about this?.
I have already tried to set the "origin" property of the player to my domain.This did not help.
This is an Example from the above link where the origin is set
<iframe id="player" type="text/html" width="640" height="390"
src="http://www.youtube.com/embed/M7lc1UVf-VE?enablejsapi=1&origin=http://example.com"
frameborder="0"></iframe>
If anyone knows of any other way to legally play VEVO content please let me know. :).Any legal loopholes will also do :D.
I have played some vevo videos just by placing the ID.
Sometimes vevo videos have certain restractions for embedding like for example, the country from the user is fetching the video.
What is the best way of making a live stream embed SWF Player Radio from http://streamcyclone.com/ Works on iphone safari
could not find any help topic on this any where all talks about converting locally and upload to the server
<embed type="application/x-shockwave-flash"
src="http://manage.streamcyclone.com/player/player.swf" width="260" height="80"
style="undefined" id="mpl" name="mpl" quality="high" allowfullscreen="true"
allowscriptaccess="always" wmode="opaque" flashvars="****************">
it's simple you can use
https://github.com/devgeeks/phonegap-plugins/tree/AudioStreamer/iPhone/AudioStream
it is a phonegap plugin(official) just for streaming audio files. use it just like what is says in read.me.
I'm making a Samsung Smart TV application. I need to play youtube videos.
Does anyone have any idea how to do this? I tried youtube js api but when the function playVideo() is executing the video just starts loading but not playing.
I have Samsung Smart TV 2012 so the SDK is 3.5
First of all check if your youtube video has granted access for mobile devices.
Second you have to disable advertisements on that video - as videos with advertisements doesn't work yet on TV devices.
Sometimes it takes a while after playVideo() to start playing the video, especially when you bind to some player events, so try to wait half or one minute.
If this won't help, please paste your code here - youtube embedding and your JS calls and I'll try to help.
EDIT
Try to use flash embedding like in Samsung docs.
As a movie parameter pass the src to YouTube API player:
<object type="application/x-shockwave-flash" id="playerObject">
<param name="movie" value="http://www.youtube.com/apiplayer?&enablejsapi=1"></param>
<param name="allowScriptAccess" value="always"></param>
<param name="allowFullScreen" value="true"></param>
<param name="wmode" value="transparent"></param>
</object>
And use this methods:
var ytPlayer = null;
function onYouTubePlayerReady() {
ytPlayer = document.getElementById('playerObject');
if (ytPlayer) {
ytPlayer.addEventListener('onStateChange','onChange');
ytPlayer.addEventListener('onError', 'onError');
ytPlayer.cueVideoById('i4iDWXstrWY'); //load video for play http://www.youtube.com/watch?v=i4iDWXstrWY
} else {
alert("error");
}
}
function onChange(newState) {
//Possible values are unstarted (-1), ended (0), playing (1), paused (2), buffering (3), video cued (5)
switch (newState) {
case 5:
ytPlayer.playVideo();
break;
}
function onError(errorCode) {
alert(errorCode);
}
When the player is ready, the API will call the onYouTubePlayerReady callback function. I think that in your solution you are missing the cueVideoById method. As it is said in YT API doc
Plays the currently cued/loaded video.
I really shouldn't be telling you guys this because you'll be able to make apps that compete with mine... but out of frustration with Samsung I will tell you: just host the darn thing as a webpage on a web server (using whatever YouTube API you like, or no API and just changing up the embed code on page load), control which video it plays using a querystring argument, then iFrame it into your Samsung Smart TV app. YouTube has severe embedding restrictions if you try and embed in an app that is not a web page... so stick in web page, then stick web page in app.
This is the general architecture you use for ANY in-app content on a Samsung Smart TV that needs to run in a web browser. The Samsung browser is blessed with being an HTML5 browser that also supports Flash. Samsung Smart TV apps allow IFraming of web content with absolutely no security restrictions. Put 2 and 2 together and you can pretty much do whatever you want on these glorified toasters... keeping in mind that you want to UNLOAD these IFrames (setting their SRC attribute to "" using JQuery is an adequate way to do this) when you change scenes because they do not unload themselves and these TVs have very little RAM.
Have fun guys :)
Or open them in a UIWebView? Their videos are in .swf format though.
Thank you.
EDIT: Okay, so I can get it to play in UIWebView, also when you click on the video in the UIWebView it will play the video in fullscreen. So am wondering if I can just get the code of when it clicks to fullscreen, and use it in some button I have.
Did that make sense?
Oh and thank you again.
Try embed the iframe snippet from Youku into your webview
<iframe height="498" width="510" frameborder="0" allowfullscreen
src="http://player.youku.com/embed/XNTY4ODU0NzQ0"></iframe>
I got it working on Android, but not tried it on iOS yet.
<video width="480" height="320"
src="http://v.youku.com/player/getRealM3U8/vid/XMzkxMTM3MDQw/type//video.m3u8"
controls>
<embed src="http://player.youku.com/player.php/sid/XMzkxMTM3MDQw/v.swf"
allowFullScreen="true" quality="high" width="480" height="320"
align="middle" allowScriptAccess="always"
type="application/x-shockwave-flash"></embed>
</video>
Just use the above HTML in a UIWebView for Youku. It can be played on iOS device and PC. Replace the XMzkxMTM3MDQw with the corresponding code of the video.
As you will easily be able to verify on the internet, Flash (.swf) is not supported on iOS devices. Maybe they offer their videos in another format, otherwise this won't work.
Update: I guess you're just opening the website in your web view. So that means on their web site they have an iOS compatible stream. You can fetch the stream data from the website's source code and build your own web site (stored locally on the device) that only displays that video stream in an UIWebView. Or you use MPMoviePlayer or HTTPLiveStream, whatever. However, make sure that this is allowed/legal, I can't help you there since I guess it heavily depends on what you want to do with your app.
See here to get the url of .m3u8 file for a youku video by its ID, and simply embed it into a <video> tag