Allows web sites to register themselves as possible handlers for content of a particular MIME type.
navigator.registerContentHandler(mimeType, uri, title);
mimeType
is the desired MIME type as a string.uri
is the URI to the handler as a string.title
is the title of the handler presented to the user as a string.navigator.registerContentHandler( "application/vnd.mozilla.maybe.feed", "http://www.example.tld/?foo=%s", "My Feed Reader" );
For Firefox 2 and above, only the application/vnd.mozilla.maybe.feed
, application/atom+xml
, and application/rss+xml
MIME types are supported. All values have the same effect, and the registered handler will receive feeds in all Atom and RSS versions (see bug 391286).
Specification | Status | Comment |
---|---|---|
WHATWG HTML Living Standard The definition of 'registerContentHandler()' in that specification. | Living Standard |
© 2005–2017 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/navigator/registerContentHandler