IOSSharePoint

SharePoint MP4 not working on IOS

2 Mins read
  • SharePoint MP4 not working on IOS
  • SharePoint MIME type at the Server Level

I had an issue previously where uploaded .mp4 video in SharePoint will not playing on iPhone and iPad

What to do


to do this you have to do two steps:

  1. Configure the BlobCache in web.config
  2. Configure IIS to provide a MIME type for .mp4 files at server level. 

Solution


Step 1: Configure the BlobCache in web.config

You turn on Blob Cache by updating the web.config files for your web application(s). in your web.config already you will have entry looks like:

<BlobCache location="C:\BlobCache\14" 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="false" />

Enable it to be look like the next XML by setting the enabled attribute to be true enabled="true"  and make sure you have enough space at your server to store the cache, the folder will created automatically no need to create a folder at your c: drive. 

<BlobCache location="C:\BlobCache\14" 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" />

Step 2: to configure the MIME Type you MUST set the MIME Type at Server Level not Web Site Level, The screen capture below shows the MIME type being set at the Server level in IIS

Adding the MIME type at the site level with BlobCache will results in the MP4 being displayed as encoded text.

I tried many solution on internet but when i applied the BlobCache the video still displayed as encoded text, i checked the ULS log and found the following:

No configured MIME type for requested file

C:\BLOBCACHE\14\465937878\PHZPZVZDLKS1UF0CDDRVCG\MEDIAFILES\DESIGN_TECHNOLOGY_GRADE_5_MEDIA_FILES_\MEDIA 2.1-DchGOiLf8kC0HC++ReHVvA.MP4'

Cause:  The cause is that SharePoint looks to the Server Level for the MIME Map. PublishingHttpModule handles the Authorize request, and looks up the mime map during this process.


The mime map reads the information from the machine level, not the site level.

Solution:  Set the MIME type at the Server Level. 

Clear the browser cache and test again, Cheers 🙂


Related posts
SharePoint

SharePoint - Only Content controls are allowed directly in a content page that contains Content controls

1 Mins read
I was working on SharePoint migration from 2010 to 2016 for a customer today. I checked some custom page layout using Visual…
SharePoint

CKSDev for Visual Studio 2015-2019

1 Mins read
How can you install CKSDev plugin for Visual Studio 2015-2019

Leave a Reply

Your email address will not be published. Required fields are marked *

×
TechnologyVideo

Apple New video Policies for iOS 10