Correct mime type for .mp4

VideoHtml5 VideoMime Types

Video Problem Overview


I have two applications as mentioned below:

  1. Admin application through which I am able to upload a .mp4 file to the server.
  2. I am trying to download the .mp4 using mobile application in iPad.

  • The Admin application is made by using asp.net 4.0 and SQL Server, IIS7.
  • The Mobile application is made of asp.net mvc3, jquerymobile, HTML5.

As of now I have added mime type video/mp4 for .mp4 in IIS7 mime types section.

When I am trying to download the .mp4 file in iPad I am seeing a dark black screen with cross arrow on it. Can anyone please help me to resolve the issue.

Please tell me whether the mime type video/mp4 for .mp4 is correct.

Video Solutions


Solution 1 - Video

According to RFC 4337 § 2, video/mp4 is indeed the correct Content-Type for MPEG-4 video.

Generally, you can find official MIME definitions by searching for the file extension and "IETF" or "RFC". The RFC (Request for Comments) articles published by the IETF (Internet Engineering Taskforce) define many Internet standards, including MIME types.

Solution 2 - Video

video/mp4should be used when you have video content in your file. If there is none, but there is audio, you should use audio/mp4. If no audio and no video is used, for instance if the file contains only a subtitle track or a metadata track, the MIME should be application/mp4. Also, as a server, you should try to include the codecs or profiles parameters as defined in RFC6381, as this will help clients determine if they can play the file, prior to downloading it.

Solution 3 - Video

Solution 4 - Video

When uploading .mp4 file into Perl script, using CGI.pm I see it as video/mp when printing out Content-type for the uploaded file. I hope it will help someone.

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
Questionsantosh kumar patroView Question on Stackoverflow
Solution 1 - VideoTRiGView Answer on Stackoverflow
Solution 2 - VideocconcolatoView Answer on Stackoverflow
Solution 3 - VideocoderView Answer on Stackoverflow
Solution 4 - VideoArseniiView Answer on Stackoverflow