mp4 video not playing only on ipad using HTML5 video - ios

We experience an issue with playing a mp4 file on ipad on webpage with a video HTML 5 player.
Issue:
It does not work on ipad/iphone. On all other platforms (Windows,Android, iOS desktop) it works fine.
This is the code:
<video id="my-video" width="400" height="240" preload="true" controls >
<source src="/media/video/6d9ab49-9936-4194-acvb-3cd9b60521fg/myvideo.mp4" />
</video>
Connected the ipad to the Mac to debug:
A message 'requested resource cannot be found'.
Does sound very clear but does not make sense because the mp4 file is accessible when you paste the url into the browser address bar.
Already tested and checked:
set src of mp4 to fullpath (including https:// or http://) instead of
using the virtual path ;
checked hostingprovider for 'Accept-Ranges: bytes' (with partial content (206) responses) ; settings are ok
play the same mp4 file from a remote url (accessed with or without https); strange but imporant : that works !
So I guess the issue really is that the mp4 can not be found or loaded on ipad.
But why?
Hope someone can help.

Have you tried it like this, include src directly inside <video> tag?
<video id="my-video" src="/media/video/6d9ab49-9936-4194-acvb-3cd9b60521fg/myvideo.mp4" width="400" height="240" preload="true" controls></video>
If it still doesn't work try to use only video element with src, remove preload and controls. Just to see if you can get it to work. And if still no results, try to go for absolute src path.

I had this very same problem serving videos on my Liferay Portal, which works perfectly on PC and Android, but not on iOS devices. After numerous tests, I think I've finally managed to nail down the cause.
For some reason, if the video file (eg MP4) is accessible by a guest user (ie accessible without having to log on to the server), then it will work fine on iOS. However, if the file is only accessible to logged on users, it won't work.
My theory on why this happens is that iOS is probably using a different session to do the range request check than the one used to play the video file. Thus, the range request check fails because the file is inaccessible.

Related

iOS recorded video for all web browser support

In ios application, capturing video in mp4 format and uploading it to amazon server.
we are embedding this uploaded video url in html file using video tag.
The problem is, it wont play in firefox since is it doesn't support mp4 format .
in some forum and blogs I have seen that we need to provide multiple formats of video (mp4, ogg, webm etc) in html.
but uploading different file format videos to server is not a good solution.
Any solution for this to achieve, with once format from iOS device , and it need to support in at least chrome , firefox and safari browsers .
If Chrome PC/Mac, Firefox PC/Mac, and Safari Mac/iOS are what you support, then you needed to provide 2 video sources and 2 audio sources:
HTML 5 Video
src="video.mp4" type="video/mp4" codecs="avc1.4D401E, mp4a.40.2"
src="video.webm" type="video/webm" codecs="vp8.0, vorbis"
HTML 5 Audio
src="audio.m4a" type="audio/mp4" codecs="mp4a.40.5"
src="audio.ogg" type='audio/ogg; codecs="vorbis"
I agree, it's ridiculous, fortunately Mozilla has given up on boycotting patent encumbered media formats and has enabled Firefox (v35) Mac to play MP4s. I just recently discovered that AAC (MP4 audio) is compatible with Chrome, Firefox, and Safari. So now life is much more simpler:
HTML 5 Media Nirvana
src="video.mp4" type="video/mp4" codecs="avc1.4D401E, mp4a.40.2"
src="audio.m4a" type="audio/mp4" codecs="mp4a.40.2"
The only browser that's left out is Opera, I can live with that.

In SharePoint 2013, the uploaded videos are not playing on ipad and iphone

I have uploaded .mp4 videos to an Assest Library in SharePoint 2013. I can play these videos on IE and other browers but I am unable to play them on IPhone and IPAD. It is asking for Silverlight Installation. Is there any way I can play my videos on them.
Please help me.
Thanks.
I was in the same situation. You need to make an additional extra change. Initially I couldn't believe, but it is necessary to enable the blobcache for that SharePoint web application that is hosting the mp4 files in order to make them available for iPad / iPhone. When you enable the blobcache please make sure you have mp4 added as extension.
Here is an example of how the blobcache entry should look like in your web.config file. Of course please add the required adjustments based on your environment: cache location, size, extensions...
<BlobCache location="D:\SPS\BlobCache" path="\.(gif|jpg|jpeg|jpe|jfif|bmp|dib|tif|tiff|themedbmp|themedcss|themedgif|themedjpg|themedpng|ico|png|wdp|hdp|css|js|asf|avi|flv|m4v|mov|mp3|mp4|mpeg|mpg|rm|rmvb|wma|wmv|ogg|ogv|oga|webm|xap)$" maxSize="10" enabled="true" />
You are not going to be able to get Silverlight on an Iphone/Ipad.
You should be able to simply download the mp4 files and play them direct from your device.
I had a video rendition set in the asset library and this caused a different video menu, and prompted to install Silverlight. Set the video properties so it forces the main video as default and it should play on iPad.
Cheers.

MP4 Videos on website embed with html5 does not play on iOS

So I have a couple of videos on my website that I shot using the iPhone 4 and then converted to mp4, webm and ogg, so that I can use them with html5. Thing is, the video does not play at all on the 4 iOS devices that I tested and neither on Chrome for Android.
The Chrome issue could be because some of the mp4 are actually m4v files, but still after encoding with handbrake a video to the iphone 4 presset and in mp4 format, it still does not play.
What happens, you ask? Well, it shows the play button crossed out with a diagonal bar, the debug console on Safari does not show any message untill I try to access the video directly. Then it says: QuickTime Movie could not be played.
What can I do? I have been trying to encode with ffmpeg, have tried a handful of different solutions, some even found here on stackoverlow, but to no avail. The videos do get shorter, both in display size and MBs, but nothing works to fix the issue at hand.
I've been trying to get this corrected for a couple of weeks now. Any help and/or suggestions are welcome.
Thank you.
By the way, all the videos are on a registred users section of the website, but I have one for debugin on the main page, so feel free to test.
https://sidnerwebsite.sytes.net
It seems the issue is caused by the iOS' need of an Intermediate Certificate trusted by the iOS to play videos through an SSL connection. After disabling the re-routing of the website to its ssl counterpart, the videos display correctly on iOS.

Mac vs. iOS safari src path requirements for playing html5 videos?

I'm having trouble understanding why videos i have stored on my server can't be played on iOS Safari but can be played on Mac Safari. I took these videos from this page.
To show you what I mean, the following works on Mac and iOS Safari:
<video src="http://video-js.zencoder.com/oceans-clip.mp4"></video>
Whereas this only works on Mac but not iOS Safari:
<video src="http://mysite.com/oceans-clip.mp4" ></video>
I'm totally confused since they are the same exact videos. Any thoughts would be greatly appreciated.
It is most likely because you have a self signed certificate for SSL. I ran into the same problem. iOS doesnt play video html from self signed certs.
According to the official Safari Developper Library, you should add "controls"
<video src="http://mysite.com/oceans-clip.mp4" controls ></video>
just a suggestion but are the mime types properly configured on your server? some browsers are pickier than other with mime types...
If you go to an URL of the video file in Firefox and use an extension like livehttpheaders you should be able to see which mime type the file is sent as, it will probably need to be corrected in your config - google should tell you how to do this. :-)

YouTube video fails to load with iOS UIWebView

W're developing an iPad app (iOS 4.3.5) that uses UIWebView to load YouTube videos. About once in five times a YouTube video will fail to load and I only see the following blank screen with YouTube's logo:
Looking in the debug logs I can only see the following warnings:
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.3.5 (8L1)/Symbols/System/Library/Internet Plug-Ins/QuickTime Plugin.webplugin/QuickTime Plugin (file not found).
warning: No copy of QuickTime Plugin.webplugin/QuickTime Plugin found locally, reading from memory on remote device. This may slow down the debug session.
I've read about this warning (https://stackoverflow.com/questions/7149593/warning-while-playing-a-video-link-in-my-app) and don't think it effects this problem.
Does anyone know how to fix this?
Try with video tag of HTML 5. I have done the same thing with video tag and its working perfect with my application.
Below is the sample code for the same...
<html><head><video controls=\"controls\"><source src=\"%#\" type=\"video/mp4\" height=\"%0.0f\" width=\"%0.0f\"/></video></body></html>
(Answering my own questions)
OK. I'm pretty sure I figured this out. Some videos don't have a mobile player. You can look at the JSON output here:
http://gdata.youtube.com/feeds/api/videos/TWfph3iNC-k?v=2&alt=jsonc
And here:
http://gdata.youtube.com/feeds/api/videos/cd4jvtAr8JM?v=2&alt=jsonc
Notice how the second video (cd4jvtAr8JM) doesn't have the mobile player link. I guess this means that YouTube hasn't encoded it yet for mobile. Or it's restricted for mobile. Regardless, these type of videos all won't play for me.

Resources