Resource Interpreted as Script But Transferred with Mime Type Text/X-C++

How do I set a MIME type before sending a file in Node.js?

I figured it out!

Thanks to @rdrey's link and this node module I managed to correctly set the MIME type of the response, like this:

function handler(req, res) {
var url = convertURL(req.url);

if (okURL(url)) {
fs.readFile(url, function(err, data) {
if (err) {
res.writeHead(404);
return res.end("File not found.");
}

res.setHeader("Content-Type", mime.lookup(url)); //Solution!
res.writeHead(200);
res.end(data);
});
} else {
res.writeHead(403);
return res.end("Forbidden.");
}
}

finfo returns wrong MIME type on some JS files (text/x-c++)?

I ran into the same issue the other day (with PDF files being uploaded as application/data), as far as I know this is a browser issue and not a server side one, as I had two browsers upload the exact same PDF, one said application/PDF and the other application/data, my only suggestion to you use since checking the content type is somewhat flaky, you should do your own type checking.

For your case, I would just ensure that the mime type starts with "text/", and check the file extension of the uploaded file. If you're particularlly brave you may write some code that does a syntax check of the uploaded file, but that's probably going to be a lot more work than you want to do.

What is a correct MIME type for .docx, .pptx, etc.?

Here are the correct Microsoft Office MIME types for HTTP content streaming:

Extension MIME Type
.doc application/msword
.dot application/msword

.docx application/vnd.openxmlformats-officedocument.wordprocessingml.document
.dotx application/vnd.openxmlformats-officedocument.wordprocessingml.template
.docm application/vnd.ms-word.document.macroEnabled.12
.dotm application/vnd.ms-word.template.macroEnabled.12

.xls application/vnd.ms-excel
.xlt application/vnd.ms-excel
.xla application/vnd.ms-excel

.xlsx application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
.xltx application/vnd.openxmlformats-officedocument.spreadsheetml.template
.xlsm application/vnd.ms-excel.sheet.macroEnabled.12
.xltm application/vnd.ms-excel.template.macroEnabled.12
.xlam application/vnd.ms-excel.addin.macroEnabled.12
.xlsb application/vnd.ms-excel.sheet.binary.macroEnabled.12

.ppt application/vnd.ms-powerpoint
.pot application/vnd.ms-powerpoint
.pps application/vnd.ms-powerpoint
.ppa application/vnd.ms-powerpoint

.pptx application/vnd.openxmlformats-officedocument.presentationml.presentation
.potx application/vnd.openxmlformats-officedocument.presentationml.template
.ppsx application/vnd.openxmlformats-officedocument.presentationml.slideshow
.ppam application/vnd.ms-powerpoint.addin.macroEnabled.12
.pptm application/vnd.ms-powerpoint.presentation.macroEnabled.12
.potm application/vnd.ms-powerpoint.template.macroEnabled.12
.ppsm application/vnd.ms-powerpoint.slideshow.macroEnabled.12

.mdb application/vnd.ms-access

For further details check out this TechNet article and this blog post.

how to download files with different extension with send_file command

I solved this problem by making a slight change on the def file_extension to

def file_extension
up = Uploadedfile.find(params[:id])
ext = File.extname("#{up.upload_file}")
if (ext == ".pdf")
"application/pdf"
elsif (ext == ".doc") || ( ext == ".rtf") || ( ext == ".docx")
"application/vnd.openxmlformats-officedocument.wordprocessingml.document"
elsif (ext == ".txt")
"text/Plain"
elsif (ext == ".rar")
"Application/x-rar-compressed"
elsif (ext == ".jpeg" || ext==".jpg")
"image/jpeg"
else
"Application/octet-stream"
end
end

I changed this part to ext = File.extname(@uploadedfile.name) to ext = File.extname("#{up.upload_file}") where up = Uploadedfile.find(params[:id])

TypeError: $(.slide-out-div).tabSlideOut is not a function

If you have a debugger in your browser, most modern ones do so press F12 to check it, then you can see if all the scripts get loaded correctly and with the typeof function you can check what tabSlideOut is (undefined or function).

I think you copy pasted it from here: http://www.building58.com/examples/tabSlideOut.html. Can you double check if you copied everything, including css, correctly?

Convert MIME type to file Extension PHP

You could use something like:

function getExtension ($mime_type){

$extensions = array('image/jpeg' => 'jpeg',
'text/xml' => 'xml'
);

// Add as many other Mime Types / File Extensions as you like

return $extensions[$mime_type];

}

Note: not every MIME type has a fixed file extension. Also, MIME types like application/octet-stream can refer to multiple file extensions.

Does PHP have a function that returns the correct file extension given a valid content type?

Given the limited number of file types stored within my application's database, the following class/method was an acceptable solution.

<?php
class AppUtil
{
public static function FileExt($contentType)
{
$map = array(
'application/pdf' => '.pdf',
'application/zip' => '.zip',
'image/gif' => '.gif',
'image/jpeg' => '.jpg',
'image/png' => '.png',
'text/css' => '.css',
'text/html' => '.html',
'text/javascript' => '.js',
'text/plain' => '.txt',
'text/xml' => '.xml',
);
if (isset($map[$contentType]))
{
return $map[$contentType];
}

// HACKISH CATCH ALL (WHICH IN MY CASE IS
// PREFERRED OVER THROWING AN EXCEPTION)
$pieces = explode('/', $contentType);
return '.' . array_pop($pieces);
}
}

echo AppUtil::FileExt('application/zip'); // prints '.zip'

Before settling on the above solution though, I did some searching on Google (as suggested by @whichdan) and found the following "extension to MIME type" mapping resource.

http://www.webmaster-toolkit.com/mime-types.shtml

After doing some analysis on the data presented in the above URL it became clear that there isn't a definitive solution for this problem (which is probably why there isn't a "content type to file extension" function in PHP).

To illustrate this fact for the benefit of the Stack Overflow community, I parsed the data presented in the above URL and split each content type into one of two categories - either "DEFINITIVE" OR "AMBIGUOUS". Running var_export on each of my "post parse" arrays results in the following PHP code.

<?php
// DEFINITIVE "CONTENT TYPE TO FILE EXTENSION" MAPPINGS
$definitive = array (
'application/x-authorware-bin' => '.aab',
'application/x-authorware-map' => '.aam',
'application/x-authorware-seg' => '.aas',
'text/vnd.abc' => '.abc',
'video/animaflex' => '.afl',
'application/x-aim' => '.aim',
'text/x-audiosoft-intra' => '.aip',
'application/x-navi-animation' => '.ani',
'application/x-nokia-9000-communicator-add-on-software' => '.aos',
'application/mime' => '.aps',
'application/arj' => '.arj',
'image/x-jg' => '.art',
'text/asp' => '.asp',
'application/x-mplayer2' => '.asx',
'video/x-ms-asf-plugin' => '.asx',
'audio/x-au' => '.au',
'application/x-troff-msvideo' => '.avi',
'video/avi' => '.avi',
'video/msvideo' => '.avi',
'video/x-msvideo' => '.avi',
'video/avs-video' => '.avs',
'application/x-bcpio' => '.bcpio',
'application/mac-binary' => '.bin',
'application/macbinary' => '.bin',
'application/x-binary' => '.bin',
'application/x-macbinary' => '.bin',
'image/x-windows-bmp' => '.bmp',
'application/x-bzip' => '.bz',
'application/vnd.ms-pki.seccat' => '.cat',
'application/clariscad' => '.ccad',
'application/x-cocoa' => '.cco',
'application/cdf' => '.cdf',
'application/x-cdf' => '.cdf',
'application/java' => '.class',
'application/java-byte-code' => '.class',
'application/x-java-class' => '.class',
'application/x-cpio' => '.cpio',
'application/mac-compactpro' => '.cpt',
'application/x-compactpro' => '.cpt',
'application/x-cpt' => '.cpt',
'application/pkcs-crl' => '.crl',
'application/pkix-crl' => '.crl',
'application/x-x509-user-cert' => '.crt',
'application/x-csh' => '.csh',
'text/x-script.csh' => '.csh',
'application/x-pointplus' => '.css',
'text/css' => '.css',
'application/x-deepv' => '.deepv',
'video/dl' => '.dl',
'video/x-dl' => '.dl',
'application/commonground' => '.dp',
'application/drafting' => '.drw',
'application/x-dvi' => '.dvi',
'drawing/x-dwf (old)' => '.dwf',
'model/vnd.dwf' => '.dwf',
'application/acad' => '.dwg',
'application/dxf' => '.dxf',
'text/x-script.elisp' => '.el',
'application/x-bytecode.elisp (compiled elisp)' => '.elc',
'application/x-elc' => '.elc',
'application/x-esrehber' => '.es',
'text/x-setext' => '.etx',
'application/envoy' => '.evy',
'application/vnd.fdf' => '.fdf',
'application/fractals' => '.fif',
'image/fif' => '.fif',
'video/fli' => '.fli',
'video/x-fli' => '.fli',
'text/vnd.fmi.flexstor' => '.flx',
'video/x-atomic3d-feature' => '.fmf',
'image/vnd.fpx' => '.fpx',
'image/vnd.net-fpx' => '.fpx',
'application/freeloader' => '.frl',
'image/g3fax' => '.g3',
'image/gif' => '.gif',
'video/gl' => '.gl',
'video/x-gl' => '.gl',
'application/x-gsp' => '.gsp',
'application/x-gss' => '.gss',
'application/x-gtar' => '.gtar',
'multipart/x-gzip' => '.gzip',
'application/x-hdf' => '.hdf',
'text/x-script' => '.hlb',
'application/hlp' => '.hlp',
'application/x-winhelp' => '.hlp',
'application/binhex' => '.hqx',
'application/binhex4' => '.hqx',
'application/mac-binhex' => '.hqx',
'application/mac-binhex40' => '.hqx',
'application/x-binhex40' => '.hqx',
'application/x-mac-binhex40' => '.hqx',
'application/hta' => '.hta',
'text/x-component' => '.htc',
'text/webviewhtml' => '.htt',
'x-conference/x-cooltalk' => '.ice ',
'image/x-icon' => '.ico',
'application/x-ima' => '.ima',
'application/x-httpd-imap' => '.imap',
'application/inf' => '.inf ',
'application/x-internett-signup' => '.ins',
'application/x-ip2' => '.ip ',
'video/x-isvideo' => '.isu',
'audio/it' => '.it',
'application/x-inventor' => '.iv',
'i-world/i-vrml' => '.ivr',
'application/x-livescreen' => '.ivy',
'audio/x-jam' => '.jam ',
'application/x-java-commerce' => '.jcm ',
'image/x-jps' => '.jps',
'application/x-javascript' => '.js ',
'image/jutvision' => '.jut',
'music/x-karaoke' => '.kar',
'application/x-ksh' => '.ksh',
'text/x-script.ksh' => '.ksh',
'audio/x-liveaudio' => '.lam',
'application/lha' => '.lha',
'application/x-lha' => '.lha',
'application/x-lisp' => '.lsp ',
'text/x-script.lisp' => '.lsp ',
'text/x-la-asf' => '.lsx',
'application/x-lzh' => '.lzh',
'application/lzx' => '.lzx',
'application/x-lzx' => '.lzx',
'text/x-m' => '.m',
'audio/x-mpequrl' => '.m3u ',
'application/x-troff-man' => '.man',
'application/x-navimap' => '.map',
'application/mbedlet' => '.mbd',
'application/x-magic-cap-package-1.0' => '.mc$',
'application/mcad' => '.mcd',
'application/x-mathcad' => '.mcd',
'image/vasa' => '.mcf',
'text/mcf' => '.mcf',
'application/netmc' => '.mcp',
'application/x-troff-me' => '.me ',
'application/x-frame' => '.mif',
'application/x-mif' => '.mif',
'www/mime' => '.mime ',
'audio/x-vnd.audioexplosion.mjuicemediafile' => '.mjf',
'video/x-motion-jpeg' => '.mjpg ',
'application/x-meme' => '.mm',
'audio/mod' => '.mod',
'audio/x-mod' => '.mod',
'audio/x-mpeg' => '.mp2',
'video/x-mpeq2a' => '.mp2',
'audio/mpeg3' => '.mp3',
'audio/x-mpeg-3' => '.mp3',
'application/vnd.ms-project' => '.mpp',
'application/marc' => '.mrc',
'application/x-troff-ms' => '.ms',
'application/x-vnd.audioexplosion.mzz' => '.mzz',
'application/vnd.nokia.configuration-message' => '.ncm',
'application/x-mix-transfer' => '.nix',
'application/x-conference' => '.nsc',
'application/x-navidoc' => '.nvd',
'application/oda' => '.oda',
'application/x-omc' => '.omc',
'application/x-omcdatamaker' => '.omcd',
'application/x-omcregerator' => '.omcr',
'text/x-pascal' => '.p',
'application/pkcs10' => '.p10',
'application/x-pkcs10' => '.p10',
'application/pkcs-12' => '.p12',
'application/x-pkcs12' => '.p12',
'application/x-pkcs7-signature' => '.p7a',
'application/x-pkcs7-certreqresp' => '.p7r',
'application/pkcs7-signature' => '.p7s',
'text/pascal' => '.pas',
'image/x-portable-bitmap' => '.pbm ',
'application/vnd.hp-pcl' => '.pcl',
'application/x-pcl' => '.pcl',
'image/x-pict' => '.pct',
'image/x-pcx' => '.pcx',
'application/pdf' => '.pdf',
'audio/make.my.funk' => '.pfunk',
'image/x-portable-graymap' => '.pgm',
'image/x-portable-greymap' => '.pgm',
'application/x-newton-compatible-pkg' => '.pkg',
'application/vnd.ms-pki.pko' => '.pko',
'text/x-script.perl' => '.pl',
'application/x-pixclscript' => '.plx',
'text/x-script.perl-module' => '.pm',
'application/x-portable-anymap' => '.pnm',
'image/x-portable-anymap' => '.pnm',
'model/x-pov' => '.pov',
'image/x-portable-pixmap' => '.ppm',
'application/powerpoint' => '.ppt',
'application/x-mspowerpoint' => '.ppt',
'application/x-freelance' => '.pre',
'paleovu/x-pv' => '.pvu',
'text/x-script.phyton' => '.py ',
'applicaiton/x-bytecode.python' => '.pyc ',
'audio/vnd.qcelp' => '.qcp ',
'video/x-qtc' => '.qtc',
'audio/x-realaudio' => '.ra',
'application/x-cmu-raster' => '.ras',
'image/x-cmu-raster' => '.ras',
'text/x-script.rexx' => '.rexx ',
'image/vnd.rn-realflash' => '.rf',
'image/x-rgb' => '.rgb ',
'application/vnd.rn-realmedia' => '.rm',
'audio/mid' => '.rmi',
'application/ringing-tones' => '.rng',
'application/vnd.nokia.ringing-tone' => '.rng',
'application/vnd.rn-realplayer' => '.rnx ',
'image/vnd.rn-realpix' => '.rp ',
'text/vnd.rn-realtext' => '.rt',
'application/x-rtf' => '.rtf',
'video/vnd.rn-realvideo' => '.rv',
'audio/s3m' => '.s3m ',
'application/x-lotusscreencam' => '.scm',
'text/x-script.guile' => '.scm',
'text/x-script.scheme' => '.scm',
'video/x-scm' => '.scm',
'application/sdp' => '.sdp ',
'application/x-sdp' => '.sdp ',
'application/sounder' => '.sdr',
'application/sea' => '.sea',
'application/x-sea' => '.sea',
'application/set' => '.set',
'application/x-sh' => '.sh',
'text/x-script.sh' => '.sh',
'audio/x-psid' => '.sid',
'application/x-sit' => '.sit',
'application/x-stuffit' => '.sit',
'application/x-seelogo' => '.sl ',
'audio/x-adpcm' => '.snd',
'application/solids' => '.sol',
'application/x-pkcs7-certificates' => '.spc ',
'application/futuresplash' => '.spl',
'application/streamingmedia' => '.ssm ',
'application/vnd.ms-pki.certstore' => '.sst',
'application/sla' => '.stl',
'application/vnd.ms-pki.stl' => '.stl',
'application/x-navistyle' => '.stl',
'application/x-sv4cpio' => '.sv4cpio',
'application/x-sv4crc' => '.sv4crc',
'x-world/x-svr' => '.svr',
'application/x-shockwave-flash' => '.swf',
'application/x-tar' => '.tar',
'application/toolbook' => '.tbk',
'application/x-tcl' => '.tcl',
'text/x-script.tcl' => '.tcl',
'text/x-script.tcsh' => '.tcsh',
'application/x-tex' => '.tex',
'application/plain' => '.text',
'application/gnutar' => '.tgz',
'audio/tsp-audio' => '.tsi',
'application/dsptype' => '.tsp',
'audio/tsplayer' => '.tsp',
'text/tab-separated-values' => '.tsv',
'text/x-uil' => '.uil',
'application/i-deas' => '.unv',
'application/x-ustar' => '.ustar',
'multipart/x-ustar' => '.ustar',
'application/x-cdlink' => '.vcd',
'text/x-vcalendar' => '.vcs',
'application/vda' => '.vda',
'video/vdo' => '.vdo',
'application/groupwise' => '.vew ',
'application/vocaltec-media-desc' => '.vmd ',
'application/vocaltec-media-file' => '.vmf',
'audio/voc' => '.voc',
'audio/x-voc' => '.voc',
'video/vosaic' => '.vos',
'audio/voxware' => '.vox',
'audio/x-twinvq' => '.vqf',
'application/x-vrml' => '.vrml',
'x-world/x-vrt' => '.vrt',
'application/wordperfect6.1' => '.w61',
'audio/wav' => '.wav',
'audio/x-wav' => '.wav',
'application/x-qpro' => '.wb1',
'image/vnd.wap.wbmp' => '.wbmp',
'application/vnd.xara' => '.web',
'application/x-123' => '.wk1',
'windows/metafile' => '.wmf',
'text/vnd.wap.wml' => '.wml',
'application/vnd.wap.wmlc' => '.wmlc ',
'text/vnd.wap.wmlscript' => '.wmls',
'application/vnd.wap.wmlscriptc' => '.wmlsc ',
'application/x-wpwin' => '.wpd',
'application/x-lotus' => '.wq1',
'application/mswrite' => '.wri',
'application/x-wri' => '.wri',
'text/scriplet' => '.wsc',
'application/x-wintalk' => '.wtk ',
'image/x-xbitmap' => '.xbm',
'image/x-xbm' => '.xbm',
'image/xbm' => '.xbm',
'video/x-amt-demorun' => '.xdr',
'xgl/drawing' => '.xgz',
'image/vnd.xiff' => '.xif',
'audio/xm' => '.xm',
'application/xml' => '.xml',
'text/xml' => '.xml',
'xgl/movie' => '.xmz',
'application/x-vnd.ls-xpix' => '.xpix',
'image/xpm' => '.xpm',
'video/x-amt-showrun' => '.xsr',
'image/x-xwd' => '.xwd',
'image/x-xwindowdump' => '.xwd',
'application/x-compress' => '.z',
'application/x-zip-compressed' => '.zip',
'application/zip' => '.zip',
'multipart/x-zip' => '.zip',
'text/x-script.zsh' => '.zsh',
);

...and...

<?php
// AMBIGUOUS "CONTENT TYPE TO FILE EXTENSION" MAPPINGS
$ambiguous = array (
'x-world/x-3dmf' =>
array (
0 => '.3dm',
1 => '.3dmf',
2 => '.qd3 ',
3 => '.qd3d ',
),
'application/octet-stream' =>
array (
0 => '.a',
1 => '.arc',
2 => '.arj',
3 => '.bin',
4 => '.com',
5 => '.dump',
6 => '.exe',
7 => '.lha',
8 => '.lhx',
9 => '.lzh',
10 => '.lzx',
11 => '.o',
12 => '.psd',
13 => '.saveme',
14 => '.uu',
15 => '.zoo',
),
'text/html' =>
array (
0 => '.acgi',
1 => '.htm',
2 => '.html',
3 => '.htmls',
4 => '.htx ',
5 => '.shtml ',
),
'application/postscript' =>
array (
0 => '.ai',
1 => '.eps',
2 => '.ps',
),
'audio/aiff' =>
array (
0 => '.aif',
1 => '.aifc',
2 => '.aiff',
),
'audio/x-aiff' =>
array (
0 => '.aif',
1 => '.aifc',
2 => '.aiff',
),
'video/x-ms-asf' =>
array (
0 => '.asf',
1 => '.asx',
),
'text/x-asm' =>
array (
0 => '.asm',
1 => '.s',
),
'audio/basic' =>
array (
0 => '.au',
1 => '.snd',
),
'image/bmp' =>
array (
0 => '.bm',
1 => '.bmp',
),
'application/book' =>
array (
0 => '.boo',
1 => '.book',
),
'application/x-bzip2' =>
array (
0 => '.boz',
1 => '.bz2',
),
'application/x-bsh' =>
array (
0 => '.bsh',
1 => '.sh',
2 => '.shar',
),
'text/plain' =>
array (
0 => '.c',
1 => '.c++',
2 => '.cc',
3 => '.com',
4 => '.conf',
5 => '.cxx',
6 => '.def',
7 => '.f',
8 => '.f90',
9 => '.for',
10 => '.g',
11 => '.h',
12 => '.hh',
13 => '.idc',
14 => '.jav',
15 => '.java',
16 => '.list',
17 => '.log ',
18 => '.lst ',
19 => '.m',
20 => '.mar',
21 => '.pl',
22 => '.sdml',
23 => '.text',
24 => '.txt',
),
'text/x-c' =>
array (
0 => '.c',
1 => '.cc',
2 => '.cpp',
),
'application/x-netcdf' =>
array (
0 => '.cdf',
1 => '.nc',
),
'application/pkix-cert' =>
array (
0 => '.cer',
1 => '.crt',
),
'application/x-x509-ca-cert' =>
array (
0 => '.cer',
1 => '.crt',
2 => '.der',
),
'application/x-chat' =>
array (
0 => '.cha',
1 => '.chat',
),
'application/x-director' =>
array (
0 => '.dcr',
1 => '.dir',
2 => '.dxr',
),
'video/x-dv' =>
array (
0 => '.dif',
1 => '.dv',
),
'application/msword' =>
array (
0 => '.doc',
1 => '.dot',
2 => '.w6w',
3 => '.wiz',
4 => '.word ',
),
'image/vnd.dwg' =>
array (
0 => '.dwg',
1 => '.dxf',
2 => '.svf',
),
'image/x-dwg' =>
array (
0 => '.dwg',
1 => '.dxf',
2 => '.svf',
),
'application/x-envoy' =>
array (
0 => '.env',
1 => '.evy',
),
'text/x-fortran' =>
array (
0 => '.f',
1 => '.f77',
2 => '.f90',
3 => '.for',
),
'image/florian' =>
array (
0 => '.flo',
1 => '.turbot',
),
'audio/make' =>
array (
0 => '.funk',
1 => '.my',
2 => '.pfunk',
),
'audio/x-gsm' =>
array (
0 => '.gsd',
1 => '.gsm',
),
'application/x-compressed' =>
array (
0 => '.gz',
1 => '.tgz',
2 => '.z',
3 => '.zip',
),
'application/x-gzip' =>
array (
0 => '.gz',
1 => '.gzip',
),
'text/x-h' =>
array (
0 => '.h',
1 => '.hh',
),
'application/x-helpfile' =>
array (
0 => '.help',
1 => '.hlp',
),
'application/vnd.hp-hpgl' =>
array (
0 => '.hgl',
1 => '.hpg',
2 => '.hpgl',
),
'image/ief' =>
array (
0 => '.ief',
1 => '.iefs',
),
'application/iges' =>
array (
0 => '.iges',
1 => '.igs',
),
'model/iges' =>
array (
0 => '.iges ',
1 => '.igs',
),
'text/x-java-source' =>
array (
0 => '.jav',
1 => '.java ',
),
'image/jpeg' =>
array (
0 => '.jfif',
1 => '.jfif-tbnl',
2 => '.jpe',
3 => '.jpeg',
4 => '.jpg ',
),
'image/pjpeg' =>
array (
0 => '.jfif',
1 => '.jpe',
2 => '.jpeg',
3 => '.jpg ',
),
'audio/midi' =>
array (
0 => '.kar',
1 => '.mid',
2 => '.midi',
),
'audio/nspaudio' =>
array (
0 => '.la ',
1 => '.lma',
),
'audio/x-nspaudio' =>
array (
0 => '.la ',
1 => '.lma',
),
'application/x-latex' =>
array (
0 => '.latex ',
1 => '.ltx',
),
'video/mpeg' =>
array (
0 => '.m1v',
1 => '.m2v',
2 => '.mp2',
3 => '.mp3',
4 => '.mpa',
5 => '.mpe',
6 => '.mpeg',
7 => '.mpg',
),
'audio/mpeg' =>
array (
0 => '.m2a',
1 => '.mp2',
2 => '.mpa',
3 => '.mpg',
4 => '.mpga',
),
'message/rfc822' =>
array (
0 => '.mht',
1 => '.mhtml',
2 => '.mime ',
),
'application/x-midi' =>
array (
0 => '.mid',
1 => '.midi',
),
'audio/x-mid' =>
array (
0 => '.mid',
1 => '.midi',
),
'audio/x-midi' =>
array (
0 => '.mid',
1 => '.midi',
),
'music/crescendo' =>
array (
0 => '.mid',
1 => '.midi',
),
'x-music/x-midi' =>
array (
0 => '.mid',
1 => '.midi',
),
'application/base64' =>
array (
0 => '.mm',
1 => '.mme',
),
'video/quicktime' =>
array (
0 => '.moov',
1 => '.mov',
2 => '.qt',
),
'video/x-sgi-movie' =>
array (
0 => '.movie',
1 => '.mv',
),
'video/x-mpeg' =>
array (
0 => '.mp2',
1 => '.mp3',
),
'application/x-project' =>
array (
0 => '.mpc',
1 => '.mpt',
2 => '.mpv',
3 => '.mpx',
),
'image/naplps' =>
array (
0 => '.nap',
1 => '.naplps',
),
'image/x-niff' =>
array (
0 => '.nif',
1 => '.niff',
),
'application/pkcs7-mime' =>
array (
0 => '.p7c',
1 => '.p7m',
),
'application/x-pkcs7-mime' =>
array (
0 => '.p7c',
1 => '.p7m',
),
'application/pro_eng' =>
array (
0 => '.part ',
1 => '.prt',
),
'chemical/x-pdb' =>
array (
0 => '.pdb',
1 => '.xyz',
),
'image/pict' =>
array (
0 => '.pic',
1 => '.pict',
),
'image/x-xpixmap' =>
array (
0 => '.pm',
1 => '.xpm',
),
'application/x-pagemaker' =>
array (
0 => '.pm4 ',
1 => '.pm5',
),
'image/png' =>
array (
0 => '.png',
1 => '.x-png',
),
'application/mspowerpoint' =>
array (
0 => '.pot',
1 => '.pps',
2 => '.ppt',
3 => '.ppz',
),
'application/vnd.ms-powerpoint' =>
array (
0 => '.pot',
1 => '.ppa',
2 => '.pps',
3 => '.ppt',
4 => '.pwz ',
),
'image/x-quicktime' =>
array (
0 => '.qif',
1 => '.qti',
2 => '.qtif',
),
'audio/x-pn-realaudio' =>
array (
0 => '.ra',
1 => '.ram',
2 => '.rm',
3 => '.rmm ',
4 => '.rmp',
),
'audio/x-pn-realaudio-plugin' =>
array (
0 => '.ra',
1 => '.rmp',
2 => '.rpm',
),
'image/cmu-raster' =>
array (
0 => '.ras',
1 => '.rast',
),
'application/x-troff' =>
array (
0 => '.roff',
1 => '.t',
2 => '.tr',
),
'text/richtext' =>
array (
0 => '.rt',
1 => '.rtf',
2 => '.rtx',
),
'application/rtf' =>
array (
0 => '.rtf',
1 => '.rtx',
),
'application/x-tbook' =>
array (
0 => '.sbk ',
1 => '.tbk',
),
'text/sgml' =>
array (
0 => '.sgm ',
1 => '.sgml',
),
'text/x-sgml' =>
array (
0 => '.sgm ',
1 => '.sgml',
),
'application/x-shar' =>
array (
0 => '.sh',
1 => '.shar',
),
'text/x-server-parsed-html' =>
array (
0 => '.shtml',
1 => '.ssi',
),
'application/x-koan' =>
array (
0 => '.skd',
1 => '.skm ',
2 => '.skp ',
3 => '.skt ',
),
'application/smil' =>
array (
0 => '.smi ',
1 => '.smil ',
),
'text/x-speech' =>
array (
0 => '.spc ',
1 => '.talk',
),
'application/x-sprite' =>
array (
0 => '.spr',
1 => '.sprite ',
),
'application/x-wais-source' =>
array (
0 => '.src',
1 => '.wsrc',
),
'application/step' =>
array (
0 => '.step',
1 => '.stp',
),
'application/x-world' =>
array (
0 => '.svr',
1 => '.wrl',
),
'application/x-texinfo' =>
array (
0 => '.texi',
1 => '.texinfo',
),
'image/tiff' =>
array (
0 => '.tif',
1 => '.tiff',
),
'image/x-tiff' =>
array (
0 => '.tif',
1 => '.tiff',
),
'text/uri-list' =>
array (
0 => '.uni',
1 => '.unis',
2 => '.uri',
3 => '.uris',
),
'text/x-uuencode' =>
array (
0 => '.uu',
1 => '.uue',
),
'video/vivo' =>
array (
0 => '.viv',
1 => '.vivo',
),
'video/vnd.vivo' =>
array (
0 => '.viv',
1 => '.vivo',
),
'audio/x-twinvq-plugin' =>
array (
0 => '.vqe',
1 => '.vql',
),
'model/vrml' =>
array (
0 => '.vrml',
1 => '.wrl',
2 => '.wrz',
),
'x-world/x-vrml' =>
array (
0 => '.vrml',
1 => '.wrl',
2 => '.wrz',
),
'application/x-visio' =>
array (
0 => '.vsd',
1 => '.vst',
2 => '.vsw ',
)


Related Topics



Leave a reply



Submit