Using the mimeTypes Object : JavaScript DHTML examples (example source code) » HTML » Mime Type

JavaScript DHTML










Java Products
Java Articles
JavaScript DHTML Home  »   HTML   » [  Mime Type  ]   

 
Using the mimeTypes Object

Please note that some example is only working under IE or Firefox.


/*
Mastering JavaScript, Premium Edition
by James Jaworski 

ISBN:078212819X
Publisher Sybex CopyRight 2001
*/
<HTML>
<HEAD>
<TITLE>Determining how MIME types are handled</TITLE>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript"><!--
m=navigator.mimeTypes
for(var i=0;i<m.length;++i){
 with(document){
  writeln('<P><B>MIME type: </B>'+m[i].type+'</P>')
  writeln('<P><B>Description: </B>'+m[i].description+'</P>')
  writeln('<P><B>Suffixes: </B>'+m[i].suffixes+'</P>')
  writeln('<HR>')
 }
}
// --></SCRIPT>
</BODY>
</HTML>
Related examples in the same category
1.  Verifying a MIME Type
2.  Verifying Plug-in and MIME Type
3.  Show Browser Mime type
4.   Properties of the Mimetype Object








Home| Contact Us
Copyright 2003 - 04 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.