Play a remote MOV in a UiWebView - ios

I have a rather complex application that mostly works in a UiWebView. I would like to autoplay a MOV file from a URL full screen. My problem is that when I link to the MOV file the play icon is crossed out or video loads but does not play. Any ideas?

Are you embedding the video in html? What does your html look like?
If you're using html5 note that auto play is not permitted.
I would recommend getting things working first using a video you know if of the correct format/codec type, then when that works switch your video.
You can download a set of supported reference videos from Apples web site.
Or use this to ensure your video is of the correct format:
http://www.mirovideoconverter.com/
Also you might want to read this:
http://developer.apple.com/library/safari/#documentation/AudioVideo/Conceptual/Using_HTML5_Audio_Video/Introduction/Introduction.html

Related

For YouTube video, how to automatically display interactive transcript?

YouTube supports interactive-transcripts, using both machine-generated and user-uploaded transcripts. This is very useful for hearings, lectures, speeches, and educational videos where a visitor might want to read along or jump around. For example in this video:
https://www.youtube.com/watch?v=IY3U2GXhz44
The visitor can click on "...More" and then "Transcript" to view the interactive-transcript.
How does a video owner make that hidden feature automatically open for visitors? I cannot find any documented method for doing that through the API for either embed or linked videos. Is there an undocumented method in the API, or a URL parameter like "&action-panel-transcript=true" that works the way I'd expect it to?
As for url parameter, you can try adding &cc_load_policy=1 behind the rel=0 if it's an embedded video or &yt:cc=on at the end of the url if it's a link to the video.
Source: https://www.makeuseof.com/tag/force-subtitles-embedded-youtube-video/

Can someone explain the difference between these two Youtube URLs?

Im building a site which opens Youtube videos onsite using Shadowbox.
I have found out that linking to a video this way ...
http://www.youtube.com/watch?v=wDZFf0pm0SE
..doesn't work (Shadowbox opens, video doesnt play). But linking this way...
http://www.youtube.com/v/wDZFf0pm0SE
.. does.
Can someone explain to me what is going on here?
The /v/ link is a direct link to the video, which is used for embedding it. You use it like this:
<embed src="http://www.youtube.com/v/wDZFf0pm0SE&autoplay=1" type="application/x-shockwave-flash" wmode="transparent" width="800" height="600"></embed>
However, due to licensing restrictions some videos will fail to play in the /v/ format.
The &autoplay=1 part just tells it to start the video on page-load. (Remove it to not do that).
The normal link is used to watch the video from Youtube itself.
Hope this helps.

xcode 4 stream video check

i am unable to solve this problem and i can´t find any solution elsewhere. I am playing the streaming video from url. But want to check if the url contains any video. Does anyone know how? To be clear i do not want to download the video and then play it. And yes i am checking the internet connection before, so i know if thre is internet or no. Is there any possible way how to check this? i just have URL with String ...i tried it with connection, but the page is connectablebut is blank with no content....:(
Thanks a lot for answer!=)
Now your question didn't say what kind of video you're trying to view, but my guess for the reason the video is blank with no content would be because your iPhone (or simulator) doesn't know how to play video with the encoding that the page contains.
Also, what kind of URL are you using? does it start with the standard http:// scheme, or is it something else like rtmp:// or rtsp:// or audio:// or?
If the URL starts with only http://, the only way that I can think of to check for a video stream is to download the html source from that page and scan through it looking for stream protocols (such as the ones I've listed above).

Determine whether a YouTube video cannot be embedded in a specific site

This YouTube video can be embedded into most sites (e.g., Stackoverflow), but it cannot be embedded into Rap Genius. You can try it yourself by pasting the embed code in to Rap Genius with firebug. You'll see this:
I need a way to detect whether a video is specifically blocked from Rap Genius.
Note that this is different from checking whether a video cannot be embedded anywhere – i.e., if you GET http://gdata.youtube.com/feeds/api/videos?v=2&alt=jsonc&q=_kmeFXjjGfk, you'll see that in the JSON response, data.items[0].accessControl.embed == 'allowed'
One clue: before the video starts playing, the player makes a request to a URL that looks like this:
http://www.youtube.com/get_video_info?video_id=_kmeFXjjGfk&el=embedded&ps=default&eurl=http%3A%2F%2Frapgenius%2Ecom&hl=en_US
Which, when curled, gives this response:
status=fail&errorcode=150&reason=This+video+contains+content+from+UMG%2C+who+has+blocked+it+from+display+on+this+website.%3Cbr%2F%3E%3Cu%3E%3Ca+href%3D%27http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D_kmeFXjjGfk%26feature%3Dplayer_embedded%27+target%3D%27_blank%27%3EWatch+on+YouTube%3C%2Fa%3E%3C%2Fu%3E&fslarge=1
So maybe I can just query this URL? Will this work in all cases? Is there an "official" way of doing this?
I had the error:
This video contains content from XXX
I noticed I was using https when requesting the page containing the embedded video. Switching back to http seems to have fixed the problem.
You have all the info in http://gdata.youtube.com/feeds/api/videos?v=2&alt=jsonc&q=_kmeFXjjGfk
"status":{"value":"restricted","reason":"limitedSyndication"},"restrictions":[{"type":"country","relationship":"deny","countries":"DE"}]
March 19, 2013 -- Response is now quite different than that given above:
{"apiVersion":"2.1","data":{"updated":"2013-03-19T14:47:14.533Z","totalItems":0,"startIndex":1,"itemsPerPage":25}}

youtube: use youtube player in website

I am not sure , But is there any way to use YouTube video player for playing .flv file , which are stored in my own server.
any idea ?
I don't think so, you can only use it to play content hosted on their site, but there are plenty of other flash players around. Flowplayer is a common one, and there are loads more if you Google.
No.
You would have to upload the files to Youtube to use their player (which you can embed)
How ever there are many Youtube-like players (which will play .flv files on your own server), for example:
flvplayer
FPlayer
BitGravity
JW FLV Player
Flowplayer
Not that I'm aware of, but there are other options available that are very very similar.
Check out the JW Player here
I don't think so.
If you don't mind targetting just cutting-edge browsers though, you could make use of the HTML5 <video> tags:
<video src="path/to/your/video">Your browser doesn't support this.</video>
I know the beta versions of FF3.5 support this, but it is a new feature that's not widely supported yet.
Otherwise, use something like FlowPlayer as suggested in other responses.
Why not just upload the video to YouTube and embed the player?

Resources