IE10 audio element doesn't play my AAC (m4a) - internet-explorer-10

IE10 audio element doesn't play my AAC (m4a) files.
Should it? the content type of the files is "audio/aac".
When I check:
audio.canPlayType("audio/mp3") --> TRUE
audio.canPlayType("audio/aac") --> FALSE
audio.canPlayType("audio/m4a") --> FALSE
I thought it should but why it doesn't?
I convert my files to AAC because of IE10 and mobile safari that don't support OGG. Safari Mobile plays this AAC files well.

See the Remarks section in http://msdn.microsoft.com/en-us/library/ie/ff975061%28v=vs.85%29.aspx
Beginning with Internet Explorer 9, any audio or video content needs the correct mime type set on the server, or the files won't play. Internet Explorer 9 and later support MP3 audio, and MP4 audio and video. [...]
Media file to serve Extension setting Mime type setting
...
Audio mp4 m4a audio/mp4
...
So you need to check for audio/mp4 in your code, and also make sure that your server sends this mime-type in the content-type header.

Related

Google DoubleClickStudio - video source file

After creating a creative banner with an mp4 video in Google Web Designer and then upload that creative to DoubleClick the source file has changed from mp4 to webm. The issue here is that webm in Safari is pixelated and the creative/ad is not shown properly, while on other browsers its ok. Is there a setting in DoubleClickStudio to prevent it from transcoding the mp4 video and use the default mp4 instead ?
...1630672923/mv/u/mvi/1/pl/24/file/file.webm

How to play m4a audio file in html audio player in MAC SAFARI browser

I have implemented a web application which uses html audio player. We will be having two type of audio files
mp3
m4a
both files are playing fine in windows chrome, edge and firefox.
Regarding m4a file in safari browser it was throwing Error instead of playing.We tried with below cases
Case 1: Added Mime extension and audio type to "audio/mp4".
Case 2: Added audio type to "audio/x-m4a".
Case 3: Does not provided audio type.
<audio controls><source src="Audio.m4a" type="audio/mp4"></audio>
This would vary depending on which OS version and browser versions you have, but the following works on MacOS Catalina in both Safari and Chrome.
<audio controls>
<source src="test.m4a" type="audio/x-m4a">
<source src="test.mp3" type="audio/mp3">
Your browser does not support the audio tag.
</audio>
Note the "audio/x-m4a" type for .m4a files.
You can check for audio player type compatibility by grabbing the HTMLAudioElement and calling:
console.log("Can play m4a:" + audioElement.canPlayType('audio/x-m4a'));
Am closing this task with answer as M4A cannot be played in MAC Safari browser in html audio player tag after trying out all possible solutions across different sites

Video cannot play in Ipad, but can play on desktop with using html5 video tag

I'm using the html5 video tag to display the video call from database, but the video cannot display properly on ipad, just can display on desktop. Is it the video I calling by file path from my file server cannot support by my ipad?
Because i have do one exaple just place a video in the same folder with my .aspx file which are use to call the video. It can be work.
Example call in same folder:
<video id="myvideo" src="a.mp4" controls="true" width="703" height="400" type="video/mp4"></video>
Example call from file server:
<video id="myvideo" src="\\10.200.1.90\tgm_navi_fs\eNotice\General Notice\Article\UploadedVideos\11_140327133434_Nanotips.mp4" controls="true" width="703" height="400" type="video/mp4"></video>
src="\10.200.1.90\tgm_navi_fs\eNotice\General Notice\Article\UploadedVideos\11_140327133434_Nanotips.mp4"
It looks like the problem is that the iPad thinks you're trying to access a local file, and iOS doesn't allow users direct access to the local file system. (You'll notice, iOS apps don't generally ask you to load or save work in a folder the same way desktop apps do.)
You probably need to set up a HTTP server (a.k.a. "web server", like Apache, etc.), either on the file server itself or on another machine that has access to the file server. Then you need to change the URL to use the http protocol.
So, for example, let's say you set up your web server on the file server machine and set the root to "\tgm_navi_fs\eNotice\General Notice\Article\". The video tag would then look like:
<video id="myvideo" src="http://10.200.1.90/UploadedVideos/11_140327133434_Nanotips.mp4" controls="true" width="703" height="400" type="video/mp4"></video>
There can be a lot of reasons why the video isn't playing.
You should always provide (a piece of) your code with your question so it's easier to see what is going on.
A few things that might help you:
The HTML5 video tag is not properly set up. Look at the code at Video for everybody!. There is also a lot more info on HTML5 video's in general.
The video doesn't have the right encoding for iOS (iPad). Try Miro Converter on you MP4 to convert it to an iOS compatible MP4.
The server is sending a wrong or no MiME type. Make sure you are sending the right MIME types by putting the following in your .htacces for example.
.htaccess video MIME Types:
AddType video/mp4 f4v f4p m4v mp4
AddType video/ogg ogv
AddType video/webm webm
AddType video/x-flv flv
The flv is usually used for a Flash fallback by plugins like MediaElementJS.

IE10 not playing a video when using the <video> tag, but plays it when requesting the video directly

I have a webpage with a tag on it with the following markup:
<video width="456" height="360" controls autoplay>
<source src="Movies/Intro.mp4" type="video/mp4" />
<source src="Movies/Intro_H264.webm" type='video/webm; codecs="vp8.0, vorbis"'/>
<source src="Movies/Intro_H264.ogg" type='video/ogg; codecs="theora, vorbis"'/>
</video>
If I visit this page in IE10 it renders the video player but with an error message that reads: "Error: unsupported video type of invalid file path"
But what's odd is if I right-click on the video box and choose, Copy video URL, and then open a new tab in IE and paste in the direct URL to the video file (Movies/Intro.mp4) it plays in the browser without issue.
Also, I can visit the page using Chrome and it plays the MP4 video from the webpage without issue. All that to say, I don't think there's any issue with the video file itself or the encoding, but why is IE 10 not playing the video when it's in the tag, but it is playing it when requesting the video directly?
Any insights?
Thanks
I would check whether the mime-type is correctly being returned for the file.
Chrome will play correctly regardless of the MIME Type returned.
To check:
Press F12 to display the IE Tools Window/Pane.
Go to the Network Tab
Click Start Capturing
Browse to the page in question
Find the mp4 line
If the Type is displayed as application/octect-stream then this is your issue.
I had the same issue with IE 11 and the problem was the content type was application/octect-stream as stated by csmith. I was serving my videos from Azure storage and apparently that is the default content type.
You can change the type with Azure storage or using Azure api as shown in the post
Set Content-type of media files stored on Blob
Here is a guide for people on Amazon cloud (I did not test it)
Changing content type for Amazon
Make sure you set the web server to use MIME type video/mp4 for .mp4. I accidentally set .mp4 to use MIME type video/mpeg, the video plays in Chrome, but not in IE11.
I had this same issue which was a real pain in the ass. My solution was actually quite simple (after searching on the internet for about 4 hours).
Add this line (specific for IE) to your .htaccess file.
AddType video/mp4 .mp4 .m4v
When you paste the URL to your browser it doesn't use HTML5 player anymore, so it doesn't say that it is really a supported file; only that the file path should be valid.
According to wikipedia, IE10 supports (not only) H.264 for video and AAC for audio - these are very common formats for mp4 container. Chrome's support is much wider (video- and audio-wise).
The problem is that the Intro.mp4 file might have different formats altogether (the file could by just renamed or created using unsupported formats).
I'd look into the file using properties->details or third party programs (for example Media Info).
I don't think it is IE10's issue. The only similar one I've found is when the user was too specific using unsupported format of used codecs ([...] type='video/mp4; codecs="H.264, AAC"' [...]).
Now it is very easy to update mime type for your videos on amazon s3,
Just login and navigate to your file, under preferences you will see metadata, there you can edit content-type
Save it and reload your page.
If it directly plays find when you put the .mp4 URL into the browser make sure it's not running with the Quicktime plugin which you may have installed (especially if you use iTunes). Right click on the successfully playing video to rule that out. If it comes up with menu items related to Quicktime you may want to disable Quicktime plugin in adins and continue troubleshooting.
Sample MP4 video: http://www.w3schools.com/html/mov_bbb.mp4

MP4 file for video.js - specification

on my web application I use video.js to handle all video MP4 files. I have to specify MP4 file details for my video provider.
I want to handle FF, chrome, IE8/9 and iPad by this format.
Could you define a set of video MP4 file details which ensure that video.js will handle with this format (for example: codec, video/audio format, video format profile)?
I do not know if it will be helpful, but I use mediainfo (http://mediainfo.sourceforge.net/en) to check MP4 file's details.
Including the default code that is provided on the video js website should do enough to support the mp4 file you have (specifically "type='video/mp4'"), however, if you're intending to support Firefox, this won't be enough. FF doesn't support the mp4 file type so you'll need to encode an ogv or a webm. FF provides a plugin that can help here at firefogg.org
Hope this helps.