Friday 23 May 2014

Add new mime types to support different file extension types..

Sharepoint by default supports limited number of mime types. To extend its functionality to support other file types, we have created the below powershell script to add new mime types.

code for .ps1

Add-PsSnapin Microsoft.SharePoint.PowerShell
$URL= Read-Host "https://test.com"
$webApp = Get-SPWebApplication($URL)
$webApp.AllowedInlineDownloadedMimeTypes.Add("video/mp4")
$webApp.Update()
$webApp.AllowedInlineDownloadedMimeTypes
Remove-PsSnapin Microsoft.SharePoint.PowerShell

No comments:

Post a Comment