Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
WebPolicyDelegate.AddMimeType
Adds a mime type to the action list for the policy decisions.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
WebView | 2.7 | ✅ Yes | ❌ No | ❌ No | ❌ No | ❌ No |
MBS( "WebPolicyDelegate.AddMimeType"; type; action ) More
Parameters
Parameter | Description | Example |
---|---|---|
type | MIME Type as text. | "application/pdf" |
action | The action you want to be made. This can be "use" when file should be viewed, "download" if file should be downloaded and "ignore" if file should be ignored. | "download" |
Result
Returns OK or error.
Description
Adds a mime type to the action list for the policy decisions.Examples
Makes sure all PDF files are downloaded:
MBS( "WebDownloadDelegate.Install" ; "web" )
MBS( "WebPolicyDelegate.AddMimeType"; "application/pdf"; "download" )
Add a type to download:
MBS( "WebPolicyDelegate.AddMimeType"; "unknown/exe"; "download" )
See also
This function checks for a license.
Created 18th August 2014, last changed 11st August 2018