-<?php\r
-\r
-/***************************************************************************\\r
- * SPIP, Systeme de publication pour l'internet *\r
- * *\r
- * Copyright (c) 2001-2016 *\r
- * Arnaud Martin, Antoine Pitrou, Philippe Riviere, Emmanuel Saint-James *\r
- * *\r
- * Ce programme est un logiciel libre distribue sous licence GNU/GPL. *\r
- * Pour plus de details voir le fichier COPYING.txt ou l'aide en ligne. *\r
-\***************************************************************************/\r
-\r
-if (!defined('_ECRIRE_INC_VERSION')) return;\r
-\r
-global $tables_images, $tables_sequences, $tables_documents, $tables_mime, $mime_alias;\r
-\r
-$tables_images = array(\r
- // Images reconnues par PHP\r
- 'jpg' => 'JPEG',\r
- 'png' => 'PNG',\r
- 'gif' => 'GIF',\r
-\r
- // Autres images (peuvent utiliser le tag <img>)\r
- 'bmp' => 'BMP',\r
- );\r
-\r
-// Multimedia (peuvent utiliser le tag <embed>)\r
-\r
-$tables_sequences = array(\r
- 'aac' => 'Advanced Audio Coding',\r
- 'ac3' => 'AC-3 Compressed Audio',\r
- 'aifc' => 'Compressed AIFF Audio',\r
- 'aiff' => 'AIFF',\r
- 'amr' => 'Adaptive Multi-Rate Audio',\r
- 'anx' => 'Annodex',\r
- 'ape' => 'Monkey\'s Audio File',\r
- 'axa' => 'Annodex Audio',\r
- 'axv' => 'Annodex Video',\r
- 'asf' => 'Windows Media',\r
- 'avi' => 'AVI',\r
- 'dv' => 'Digital Video',\r
- 'f4a' => 'Audio for Adobe Flash Player',\r
- 'f4b' => 'Audio Book for Adobe Flash Player',\r
- 'f4p' => 'Protected Video for Adobe Flash Player',\r
- 'f4v' => 'Video for Adobe Flash Player',\r
- 'flac' => 'Free Lossless Audio Codec',\r
- 'flv' => 'Flash Video',\r
- 'm2p' => 'MPEG-PS',\r
- 'm2ts' => 'BDAV MPEG-2 Transport Stream',\r
- 'm4a' => 'MPEG4 Audio',\r
- 'm4b' => 'MPEG4 Audio',\r
- 'm4p' => 'MPEG4 Audio',\r
- 'm4r' => 'iPhone Ringtone',\r
- 'm4v' => 'MPEG4 Video',\r
- 'mid' => 'Midi',\r
- 'mng' => 'MNG',\r
- 'mka' => 'Matroska Audio',\r
- 'mkv' => 'Matroska Video',\r
- 'mov' => 'QuickTime',\r
- 'mp3' => 'MP3',\r
- 'mp4' => 'MPEG4',\r
- 'mpc' => 'Musepack',\r
- 'mpg' => 'MPEG',\r
- 'mts' => 'AVCHD MPEG-2 transport stream',\r
- 'oga' => 'Ogg Audio',\r
- 'ogg' => 'Ogg Vorbis',\r
- 'ogv' => 'Ogg Video',\r
- 'ogx' => 'Ogg Multiplex',\r
- 'qt' => 'QuickTime',\r
- 'ra' => 'RealAudio',\r
- 'ram' => 'RealAudio',\r
- 'rm' => 'RealAudio',\r
- 'spx' => 'Ogg Speex',\r
- 'svg' => 'Scalable Vector Graphics',\r
- 'svgz' => 'Compressed Scalable Vector Graphic',\r
- 'swf' => 'Flash',\r
- 'tif' => 'TIFF',\r
- 'ts' => 'MPEG transport stream',\r
- 'wav' => 'WAV',\r
- 'webm' => 'WebM',\r
- 'wma' => 'Windows Media Audio',\r
- 'wmv' => 'Windows Media Video',\r
- 'y4m' => 'YUV4MPEG2',\r
- '3ga' => '3GP Audio File',\r
- '3gp' => '3rd Generation Partnership Project'\r
- );\r
-\r
-// Documents varies\r
-$tables_documents = array(\r
- '7z' => '7 Zip',\r
- 'abw' => 'Abiword',\r
- 'ai' => 'Adobe Illustrator',\r
- 'asx' => 'Advanced Stream Redirector',\r
- 'bib' => 'BibTeX',\r
- 'bz2' => 'BZip',\r
- 'bin' => 'Binary Data',\r
- 'blend' => 'Blender',\r
- 'c' => 'C source',\r
- 'cls' => 'LaTeX Class',\r
- 'csl' => 'Citation Style Language',\r
- 'css' => 'Cascading Style Sheet',\r
- 'csv' => 'Comma Separated Values',\r
- 'deb' => 'Debian',\r
- 'doc' => 'Word',\r
- 'dot' => 'Word Template',\r
- 'djvu' => 'DjVu',\r
- 'dvi' => 'LaTeX DVI',\r
- 'emf' => 'Enhanced Metafile',\r
- 'enl' => 'EndNote Library',\r
- 'ens' => 'EndNote Style',\r
- 'epub' => 'EPUB',\r
- 'eps' => 'PostScript',\r
- 'gpx' => 'GPS eXchange Format',\r
- 'gz' => 'GZ',\r
- 'h' => 'C header',\r
- 'html' => 'HTML',\r
- 'jar' => 'Java Archive',\r
- 'json' => 'JSON',\r
- 'kml' => 'Keyhole Markup Language',\r
- 'kmz' => 'Google Earth Placemark File',\r
- 'lyx' => 'Lyx file',\r
- 'mathml' => 'MathML',\r
- 'mbtiles' => 'MBTiles',\r
- 'm3u' => 'M3U Playlist',\r
- 'm3u8' => 'M3U8 Playlist',\r
- 'm4u' => 'MPEG4 Playlist',\r
- 'pas' => 'Pascal',\r
- 'pdf' => 'PDF',\r
- 'pgn' => 'Portable Game Notation',\r
- 'pls' => 'Playlist',\r
- 'pot' => 'PowerPoint Template',\r
- 'ppt' => 'PowerPoint',\r
- 'ps' => 'PostScript',\r
- 'psd' => 'Photoshop',\r
- 'rar' => 'WinRAR',\r
- 'rdf' => 'Resource Description Framework',\r
- 'ris' => 'RIS',\r
- 'rpm' => 'RedHat/Mandrake/SuSE',\r
- 'rtf' => 'RTF',\r
- 'sdc' => 'StarOffice Spreadsheet',\r
- 'sdd' => 'StarOffice Presentation',\r
- 'sdw' => 'StarOffice Writer document',\r
- 'sit' => 'Stuffit',\r
- 'sla' => 'Scribus',\r
- 'srt' => 'SubRip Subtitle',\r
- 'ssa' => 'SubStation Alpha Subtitle',\r
- 'sty' => 'LaTeX Style Sheet',\r
- 'sxc' => 'OpenOffice.org Calc',\r
- 'sxi' => 'OpenOffice.org Impress',\r
- 'sxw' => 'OpenOffice.org',\r
- 'tar' => 'Tar',\r
- 'tex' => 'LaTeX',\r
- 'tgz' => 'TGZ',\r
- 'torrent' => 'BitTorrent',\r
- 'ttf' => 'TTF Font',\r
- 'txt' => 'Texte',\r
- 'usf' => 'Universal Subtitle Format',\r
- 'wmf' => 'Windows Metafile',\r
- 'wpl' => 'Windows Media Player Playlist',\r
- 'xcf' => 'GIMP multi-layer',\r
- 'xspf' => 'XSPF',\r
- 'xls' => 'Excel',\r
- 'xlt' => 'Excel Template',\r
- 'xml' => 'XML',\r
- 'y4m' => 'YUV4MPEG2',\r
- 'yaml' => 'YAML',\r
- 'zip' => 'Zip',\r
-\r
- // open document format\r
- \r
- 'odb' => 'OpenDocument Database',\r
- 'odc' => 'OpenDocument Chart',\r
- 'odf' => 'OpenDocument Formula',\r
- 'odg' => 'OpenDocument Graphics',\r
- 'odi' => 'OpenDocument Image',\r
- 'odm' => 'OpenDocument Text-master',\r
- 'odp' => 'OpenDocument Presentation',\r
- 'ods' => 'OpenDocument Spreadsheet',\r
- 'odt' => 'OpenDocument Text',\r
- 'otg' => 'OpenDocument Graphics-template',\r
- 'otp' => 'OpenDocument Presentation-template',\r
- 'ots' => 'OpenDocument Spreadsheet-template',\r
- 'ott' => 'OpenDocument Text-template',\r
-\r
-\r
- // Open XML File Formats\r
- 'docm' => 'Word',\r
- 'docx' => 'Word',\r
- 'dotm' => 'Word template',\r
- 'dotx' => 'Word template',\r
-\r
- 'potm' => 'Powerpoint template',\r
- 'potx' => 'Powerpoint template',\r
- 'ppam' => 'Powerpoint addin',\r
- 'ppsm' => 'Powerpoint slideshow',\r
- 'ppsx' => 'Powerpoint slideshow',\r
- 'pptm' => 'Powerpoint',\r
- 'pptx' => 'Powerpoint',\r
-\r
- 'xlam' => 'Excel',\r
- 'xlsb' => 'Excel binary',\r
- 'xlsm' => 'Excel',\r
- 'xlsx' => 'Excel',\r
- 'xltm' => 'Excel template',\r
- 'xltx' => 'Excel template'\r
- );\r
-\r
-$tables_mime = array(\r
- // Images reconnues par PHP\r
- 'jpg' => 'image/jpeg',\r
- 'png' => 'image/png',\r
- 'gif' => 'image/gif',\r
-\r
- // Autres images (peuvent utiliser le tag <img>)\r
- 'bmp' => 'image/x-ms-bmp', // pas enregistre par IANA, variante: image/bmp\r
- 'tif' => 'image/tiff',\r
- \r
- // Multimedia (peuvent utiliser le tag <embed>)\r
- 'aac' => 'audio/mp4a-latm',\r
- 'ac3' => 'audio/x-aac',\r
- 'aifc' => 'audio/x-aifc',\r
- 'aiff' => 'audio/x-aiff',\r
- 'amr' => 'audio/amr',\r
- 'ape' => 'audio/x-monkeys-audio',\r
- 'asf' => 'video/x-ms-asf',\r
- 'avi' => 'video/x-msvideo',\r
- 'anx' => 'application/annodex',\r
- 'axa' => 'audio/annodex',\r
- 'axv' => 'video/annodex',\r
- 'dv' => 'video/x-dv',\r
- 'f4a' => 'audio/mp4',\r
- 'f4b' => 'audio/mp4',\r
- 'f4p' => 'video/mp4',\r
- 'f4v' => 'video/mp4',\r
- 'flac' => 'audio/x-flac',\r
- 'flv' => 'video/x-flv',\r
- 'm2p' => 'video/MP2P',\r
- 'm2ts' => 'video/MP2T',\r
- 'm4a' => 'audio/mp4a-latm',\r
- 'm4b' => 'audio/mp4a-latm',\r
- 'm4p' => 'audio/mp4a-latm',\r
- 'm4r' => 'audio/aac',\r
- 'm4u' => 'video/vnd.mpegurl',\r
- 'm4v' => 'video/x-m4v',\r
- 'mid' => 'audio/midi',\r
- 'mka' => 'audio/mka',\r
- 'mkv' => 'video/mkv',\r
- 'mng' => 'video/x-mng',\r
- 'mov' => 'video/quicktime',\r
- 'mp3' => 'audio/mpeg',\r
- 'mp4' => 'application/mp4',\r
- 'mpc' => 'audio/x-musepack',\r
- 'mpg' => 'video/mpeg',\r
- 'mts' => 'video/MP2T',\r
- 'oga' => 'audio/ogg',\r
- 'ogg' => 'audio/ogg',\r
- 'ogv' => 'video/ogg',\r
- 'ogx' => 'application/ogg',\r
- 'qt' => 'video/quicktime',\r
- 'ra' => 'audio/x-pn-realaudio',\r
- 'ram' => 'audio/x-pn-realaudio',\r
- 'rm' => 'audio/x-pn-realaudio',\r
- 'spx' => 'audio/ogg',\r
- 'svg' => 'image/svg+xml',\r
- 'svgz' => 'image/svg+xml',\r
- 'swf' => 'application/x-shockwave-flash',\r
- 'ts' => 'video/MP2T',\r
- 'wav' => 'audio/x-wav',\r
- 'webm' => 'video/webm',\r
- 'wma' => 'audio/x-ms-wma',\r
- 'wmv' => 'video/x-ms-wmv',\r
- 'y4m' => 'video/x-raw-yuv',\r
- '3gp' => 'video/3gpp',\r
- '3ga' => 'audio/3ga',\r
-\r
- // Documents varies\r
- '7z' => 'application/x-7z-compressed',\r
- 'ai' => 'application/illustrator',\r
- 'abw' => 'application/abiword',\r
- 'asx' => 'video/x-ms-asf',\r
- 'bib' => 'application/x-bibtex',\r
- 'bin' => 'application/octet-stream', # le tout-venant\r
- 'blend' => 'application/x-blender',\r
- 'bz2' => 'application/x-bzip2',\r
- 'c' => 'text/x-csrc',\r
- 'csl' => 'application/xml',\r
- 'css' => 'text/css',\r
- 'csv' => 'text/csv',\r
- 'deb' => 'application/x-debian-package',\r
- 'doc' => 'application/msword',\r
- 'dot' => 'application/msword',\r
- 'djvu' => 'image/vnd.djvu',\r
- 'dvi' => 'application/x-dvi',\r
- 'emf' => 'image/x-emf',\r
- 'enl' => 'application/octet-stream',\r
- 'ens' => 'application/octet-stream',\r
- 'eps' => 'application/postscript',\r
- 'epub' => 'application/epub+zip', // pas enregistre par IANA\r
- 'gpx' => 'application/gpx+xml', // pas enregistre par IANA\r
- 'gz' => 'application/x-gzip',\r
- 'h' => 'text/x-chdr',\r
- 'html' => 'text/html',\r
- 'jar' => 'application/java-archive',\r
- 'json' => 'application/json',\r
- 'kml' => 'application/vnd.google-earth.kml+xml',\r
- 'kmz' => 'application/vnd.google-earth.kmz',\r
- 'lyx' => 'application/x-lyx',\r
- 'm3u' => 'text/plain',\r
- 'm3u8' => 'text/plain',\r
- 'mathml' => 'application/mathml+xml',\r
- 'mbtiles' => 'application/x-sqlite3',\r
- 'pas' => 'text/x-pascal',\r
- 'pdf' => 'application/pdf',\r
- 'pgn' => 'application/x-chess-pgn',\r
- 'pls' => 'text/plain',\r
- 'ppt' => 'application/vnd.ms-powerpoint',\r
- 'pot' => 'application/vnd.ms-powerpoint',\r
- 'ps' => 'application/postscript',\r
- 'psd' => 'image/x-photoshop', // pas enregistre par IANA\r
- 'rar' => 'application/x-rar-compressed',\r
- 'rdf' => 'application/rdf+xml',\r
- 'ris' => 'application/x-research-info-systems',\r
- 'rpm' => 'application/x-redhat-package-manager',\r
- 'rtf' => 'application/rtf',\r
- 'sdc' => 'application/vnd.stardivision.calc',\r
- 'sdd' => 'application/vnd.stardivision.impress',\r
- 'sdw' => 'application/vnd.stardivision.writer',\r
- 'sit' => 'application/x-stuffit',\r
- 'sla' => 'application/x-scribus',\r
- 'srt' => 'text/plain',\r
- 'ssa' => 'text/plain',\r
- 'sxc' => 'application/vnd.sun.xml.calc',\r
- 'sxi' => 'application/vnd.sun.xml.impress',\r
- 'sxw' => 'application/vnd.sun.xml.writer',\r
- 'tar' => 'application/x-tar',\r
- 'tex' => 'text/x-tex',\r
- 'tgz' => 'application/x-gtar',\r
- 'torrent' => 'application/x-bittorrent',\r
- 'ttf' => 'application/x-font-ttf',\r
- 'txt' => 'text/plain',\r
- 'usf' => 'application/xml',\r
- 'xcf' => 'application/x-xcf',\r
- 'xls' => 'application/vnd.ms-excel',\r
- 'xlt' => 'application/vnd.ms-excel',\r
- 'wmf' => 'image/x-emf',\r
- 'wpl' => 'application/vnd.ms-wpl',\r
- 'xspf' => 'application/xspf+xml',\r
- 'xml' => 'application/xml',\r
- 'yaml' => 'text/yaml',\r
- 'zip' => 'application/zip',\r
-\r
- // Open Document format\r
- 'odt' => 'application/vnd.oasis.opendocument.text',\r
- 'ods' => 'application/vnd.oasis.opendocument.spreadsheet',\r
- 'odp' => 'application/vnd.oasis.opendocument.presentation',\r
- 'odg' => 'application/vnd.oasis.opendocument.graphics',\r
- 'odc' => 'application/vnd.oasis.opendocument.chart',\r
- 'odf' => 'application/vnd.oasis.opendocument.formula',\r
- 'odb' => 'application/vnd.oasis.opendocument.database',\r
- 'odi' => 'application/vnd.oasis.opendocument.image',\r
- 'odm' => 'application/vnd.oasis.opendocument.text-master',\r
- 'ott' => 'application/vnd.oasis.opendocument.text-template',\r
- 'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',\r
- 'otp' => 'application/vnd.oasis.opendocument.presentation-template',\r
- 'otg' => 'application/vnd.oasis.opendocument.graphics-template',\r
-\r
- 'cls' => 'text/x-tex',\r
- 'sty' => 'text/x-tex',\r
-\r
- // Open XML File Formats\r
- 'docm' => 'application/vnd.ms-word.document.macroEnabled.12',\r
- 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\r
- 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12',\r
- 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template',\r
-\r
- 'potm' => 'application/vnd.ms-powerpoint.template.macroEnabled.12',\r
- 'potx' => 'application/vnd.openxmlformats-officedocument.presentationml.template',\r
- 'ppam' => 'application/vnd.ms-powerpoint.addin.macroEnabled.12',\r
- 'ppsm' => 'application/vnd.ms-powerpoint.slideshow.macroEnabled.12',\r
- 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',\r
- 'pptm' => 'application/vnd.ms-powerpoint.presentation.macroEnabled.12',\r
- 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',\r
-\r
- 'xlam' => 'application/vnd.ms-excel.addin.macroEnabled.12',\r
- 'xlsb' => 'application/vnd.ms-excel.sheet.binary.macroEnabled.12',\r
- 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12',\r
- 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\r
- 'xltm' => 'application/vnd.ms-excel.template.macroEnabled.12',\r
- 'xltx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.template'\r
- );\r
-\r
-\r
- $mime_alias = array (\r
- 'application/x-ogg' => 'application/ogg',\r
- 'audio/3gpp' => 'video/3gpp',\r
- 'audio/x-mpeg' => 'audio/mpeg',\r
- 'audio/x-musepack' => 'audio/musepack',\r
- 'audio/webm' => 'video/webm',\r
- 'video/flv' => 'video/x-flv',\r
- 'video/mp4' => 'application/mp4',\r
- 'image/jpg' => 'image/jpeg'\r
- );\r
-\r
-?>\r
+<?php
+
+/***************************************************************************\
+ * SPIP, Systeme de publication pour l'internet *
+ * *
+ * Copyright (c) 2001-2016 *
+ * Arnaud Martin, Antoine Pitrou, Philippe Riviere, Emmanuel Saint-James *
+ * *
+ * Ce programme est un logiciel libre distribue sous licence GNU/GPL. *
+ * Pour plus de details voir le fichier COPYING.txt ou l'aide en ligne. *
+\***************************************************************************/
+
+if (!defined('_ECRIRE_INC_VERSION')) {
+ return;
+}
+
+global $tables_images, $tables_sequences, $tables_documents, $tables_mime, $mime_alias;
+
+$tables_images = array(
+ // Images reconnues par PHP
+ 'jpg' => 'JPEG',
+ 'png' => 'PNG',
+ 'gif' => 'GIF',
+
+ // Autres images (peuvent utiliser le tag <img>)
+ 'bmp' => 'BMP',
+);
+
+// Multimedia (peuvent utiliser le tag <embed>)
+
+$tables_sequences = array(
+ 'aac' => 'Advanced Audio Coding',
+ 'ac3' => 'AC-3 Compressed Audio',
+ 'aifc' => 'Compressed AIFF Audio',
+ 'aiff' => 'AIFF',
+ 'amr' => 'Adaptive Multi-Rate Audio',
+ 'anx' => 'Annodex',
+ 'ape' => 'Monkey\'s Audio File',
+ 'axa' => 'Annodex Audio',
+ 'axv' => 'Annodex Video',
+ 'asf' => 'Windows Media',
+ 'avi' => 'AVI',
+ 'dv' => 'Digital Video',
+ 'f4a' => 'Audio for Adobe Flash Player',
+ 'f4b' => 'Audio Book for Adobe Flash Player',
+ 'f4p' => 'Protected Video for Adobe Flash Player',
+ 'f4v' => 'Video for Adobe Flash Player',
+ 'flac' => 'Free Lossless Audio Codec',
+ 'flv' => 'Flash Video',
+ 'm2p' => 'MPEG-PS',
+ 'm2ts' => 'BDAV MPEG-2 Transport Stream',
+ 'm4a' => 'MPEG4 Audio',
+ 'm4b' => 'MPEG4 Audio',
+ 'm4p' => 'MPEG4 Audio',
+ 'm4r' => 'iPhone Ringtone',
+ 'm4v' => 'MPEG4 Video',
+ 'mid' => 'Midi',
+ 'mng' => 'MNG',
+ 'mka' => 'Matroska Audio',
+ 'mkv' => 'Matroska Video',
+ 'mov' => 'QuickTime',
+ 'mp3' => 'MP3',
+ 'mp4' => 'MPEG4',
+ 'mpc' => 'Musepack',
+ 'mpg' => 'MPEG',
+ 'mts' => 'AVCHD MPEG-2 transport stream',
+ 'oga' => 'Ogg Audio',
+ 'ogg' => 'Ogg Vorbis',
+ 'ogv' => 'Ogg Video',
+ 'ogx' => 'Ogg Multiplex',
+ 'qt' => 'QuickTime',
+ 'ra' => 'RealAudio',
+ 'ram' => 'RealAudio',
+ 'rm' => 'RealAudio',
+ 'spx' => 'Ogg Speex',
+ 'svg' => 'Scalable Vector Graphics',
+ 'svgz' => 'Compressed Scalable Vector Graphic',
+ 'swf' => 'Flash',
+ 'tif' => 'TIFF',
+ 'ts' => 'MPEG transport stream',
+ 'wav' => 'WAV',
+ 'webm' => 'WebM',
+ 'wma' => 'Windows Media Audio',
+ 'wmv' => 'Windows Media Video',
+ 'y4m' => 'YUV4MPEG2',
+ '3ga' => '3GP Audio File',
+ '3gp' => '3rd Generation Partnership Project'
+);
+
+// Documents varies
+$tables_documents = array(
+ '7z' => '7 Zip',
+ 'abw' => 'Abiword',
+ 'ai' => 'Adobe Illustrator',
+ 'asx' => 'Advanced Stream Redirector',
+ 'bib' => 'BibTeX',
+ 'bz2' => 'BZip',
+ 'bin' => 'Binary Data',
+ 'blend' => 'Blender',
+ 'c' => 'C source',
+ 'cls' => 'LaTeX Class',
+ 'csl' => 'Citation Style Language',
+ 'css' => 'Cascading Style Sheet',
+ 'csv' => 'Comma Separated Values',
+ 'deb' => 'Debian',
+ 'doc' => 'Word',
+ 'dot' => 'Word Template',
+ 'djvu' => 'DjVu',
+ 'dvi' => 'LaTeX DVI',
+ 'emf' => 'Enhanced Metafile',
+ 'enl' => 'EndNote Library',
+ 'ens' => 'EndNote Style',
+ 'epub' => 'EPUB',
+ 'eps' => 'PostScript',
+ 'gpx' => 'GPS eXchange Format',
+ 'gz' => 'GZ',
+ 'h' => 'C header',
+ 'html' => 'HTML',
+ 'ics' => 'iCalendar',
+ 'jar' => 'Java Archive',
+ 'json' => 'JSON',
+ 'kml' => 'Keyhole Markup Language',
+ 'kmz' => 'Google Earth Placemark File',
+ 'lyx' => 'Lyx file',
+ 'mathml' => 'MathML',
+ 'mbtiles' => 'MBTiles',
+ 'm3u' => 'M3U Playlist',
+ 'm3u8' => 'M3U8 Playlist',
+ 'm4u' => 'MPEG4 Playlist',
+ 'md' => 'Markdown Document',
+ 'pas' => 'Pascal',
+ 'pdf' => 'PDF',
+ 'pgn' => 'Portable Game Notation',
+ 'pls' => 'Playlist',
+ 'pot' => 'PowerPoint Template',
+ 'ppt' => 'PowerPoint',
+ 'ps' => 'PostScript',
+ 'psd' => 'Photoshop',
+ 'rar' => 'WinRAR',
+ 'rdf' => 'Resource Description Framework',
+ 'ris' => 'RIS',
+ 'rpm' => 'RedHat/Mandrake/SuSE',
+ 'rtf' => 'RTF',
+ 'sdc' => 'StarOffice Spreadsheet',
+ 'sdd' => 'StarOffice Presentation',
+ 'sdw' => 'StarOffice Writer document',
+ 'sit' => 'Stuffit',
+ 'sla' => 'Scribus',
+ 'srt' => 'SubRip Subtitle',
+ 'ssa' => 'SubStation Alpha Subtitle',
+ 'sty' => 'LaTeX Style Sheet',
+ 'sxc' => 'OpenOffice.org Calc',
+ 'sxi' => 'OpenOffice.org Impress',
+ 'sxw' => 'OpenOffice.org',
+ 'tar' => 'Tar',
+ 'tex' => 'LaTeX',
+ 'tgz' => 'TGZ',
+ 'torrent' => 'BitTorrent',
+ 'ttf' => 'TTF Font',
+ 'txt' => 'Texte',
+ 'usf' => 'Universal Subtitle Format',
+ 'vcf' => 'vCard',
+ 'wmf' => 'Windows Metafile',
+ 'wpl' => 'Windows Media Player Playlist',
+ 'xcf' => 'GIMP multi-layer',
+ 'xspf' => 'XSPF',
+ 'xls' => 'Excel',
+ 'xlt' => 'Excel Template',
+ 'xml' => 'XML',
+ 'y4m' => 'YUV4MPEG2',
+ 'yaml' => 'YAML',
+ 'zip' => 'Zip',
+
+ // open document format
+
+ 'odb' => 'OpenDocument Database',
+ 'odc' => 'OpenDocument Chart',
+ 'odf' => 'OpenDocument Formula',
+ 'odg' => 'OpenDocument Graphics',
+ 'odi' => 'OpenDocument Image',
+ 'odm' => 'OpenDocument Text-master',
+ 'odp' => 'OpenDocument Presentation',
+ 'ods' => 'OpenDocument Spreadsheet',
+ 'odt' => 'OpenDocument Text',
+ 'otg' => 'OpenDocument Graphics-template',
+ 'otp' => 'OpenDocument Presentation-template',
+ 'ots' => 'OpenDocument Spreadsheet-template',
+ 'ott' => 'OpenDocument Text-template',
+
+
+ // Open XML File Formats
+ 'docm' => 'Word',
+ 'docx' => 'Word',
+ 'dotm' => 'Word template',
+ 'dotx' => 'Word template',
+
+ 'potm' => 'Powerpoint template',
+ 'potx' => 'Powerpoint template',
+ 'ppam' => 'Powerpoint addin',
+ 'ppsm' => 'Powerpoint slideshow',
+ 'ppsx' => 'Powerpoint slideshow',
+ 'pptm' => 'Powerpoint',
+ 'pptx' => 'Powerpoint',
+
+ 'xlam' => 'Excel',
+ 'xlsb' => 'Excel binary',
+ 'xlsm' => 'Excel',
+ 'xlsx' => 'Excel',
+ 'xltm' => 'Excel template',
+ 'xltx' => 'Excel template'
+);
+
+$tables_mime = array(
+ // Images reconnues par PHP
+ 'jpg' => 'image/jpeg',
+ 'png' => 'image/png',
+ 'gif' => 'image/gif',
+
+ // Autres images (peuvent utiliser le tag <img>)
+ 'bmp' => 'image/x-ms-bmp', // pas enregistre par IANA, variante: image/bmp
+ 'tif' => 'image/tiff',
+
+ // Multimedia (peuvent utiliser le tag <embed>)
+ 'aac' => 'audio/mp4a-latm',
+ 'ac3' => 'audio/x-aac',
+ 'aifc' => 'audio/x-aifc',
+ 'aiff' => 'audio/x-aiff',
+ 'amr' => 'audio/amr',
+ 'ape' => 'audio/x-monkeys-audio',
+ 'asf' => 'video/x-ms-asf',
+ 'avi' => 'video/x-msvideo',
+ 'anx' => 'application/annodex',
+ 'axa' => 'audio/annodex',
+ 'axv' => 'video/annodex',
+ 'dv' => 'video/x-dv',
+ 'f4a' => 'audio/mp4',
+ 'f4b' => 'audio/mp4',
+ 'f4p' => 'video/mp4',
+ 'f4v' => 'video/mp4',
+ 'flac' => 'audio/x-flac',
+ 'flv' => 'video/x-flv',
+ 'm2p' => 'video/MP2P',
+ 'm2ts' => 'video/MP2T',
+ 'm4a' => 'audio/mp4a-latm',
+ 'm4b' => 'audio/mp4a-latm',
+ 'm4p' => 'audio/mp4a-latm',
+ 'm4r' => 'audio/aac',
+ 'm4u' => 'video/vnd.mpegurl',
+ 'm4v' => 'video/x-m4v',
+ 'mid' => 'audio/midi',
+ 'mka' => 'audio/mka',
+ 'mkv' => 'video/mkv',
+ 'mng' => 'video/x-mng',
+ 'mov' => 'video/quicktime',
+ 'mp3' => 'audio/mpeg',
+ 'mp4' => 'application/mp4',
+ 'mpc' => 'audio/x-musepack',
+ 'mpg' => 'video/mpeg',
+ 'mts' => 'video/MP2T',
+ 'oga' => 'audio/ogg',
+ 'ogg' => 'audio/ogg',
+ 'ogv' => 'video/ogg',
+ 'ogx' => 'application/ogg',
+ 'qt' => 'video/quicktime',
+ 'ra' => 'audio/x-pn-realaudio',
+ 'ram' => 'audio/x-pn-realaudio',
+ 'rm' => 'audio/x-pn-realaudio',
+ 'spx' => 'audio/ogg',
+ 'svg' => 'image/svg+xml',
+ 'svgz' => 'image/svg+xml',
+ 'swf' => 'application/x-shockwave-flash',
+ 'ts' => 'video/MP2T',
+ 'wav' => 'audio/x-wav',
+ 'webm' => 'video/webm',
+ 'wma' => 'audio/x-ms-wma',
+ 'wmv' => 'video/x-ms-wmv',
+ 'y4m' => 'video/x-raw-yuv',
+ '3gp' => 'video/3gpp',
+ '3ga' => 'audio/3ga',
+
+ // Documents varies
+ '7z' => 'application/x-7z-compressed',
+ 'ai' => 'application/illustrator',
+ 'abw' => 'application/abiword',
+ 'asx' => 'video/x-ms-asf',
+ 'bib' => 'application/x-bibtex',
+ 'bin' => 'application/octet-stream', # le tout-venant
+ 'blend' => 'application/x-blender',
+ 'bz2' => 'application/x-bzip2',
+ 'c' => 'text/x-csrc',
+ 'csl' => 'application/xml',
+ 'css' => 'text/css',
+ 'csv' => 'text/csv',
+ 'deb' => 'application/x-debian-package',
+ 'doc' => 'application/msword',
+ 'dot' => 'application/msword',
+ 'djvu' => 'image/vnd.djvu',
+ 'dvi' => 'application/x-dvi',
+ 'emf' => 'image/x-emf',
+ 'enl' => 'application/octet-stream',
+ 'ens' => 'application/octet-stream',
+ 'eps' => 'application/postscript',
+ 'epub' => 'application/epub+zip', // pas enregistre par IANA
+ 'gpx' => 'application/gpx+xml', // pas enregistre par IANA
+ 'gz' => 'application/x-gzip',
+ 'h' => 'text/x-chdr',
+ 'html' => 'text/html',
+ 'ics' => 'text/calendar',
+ 'jar' => 'application/java-archive',
+ 'json' => 'application/json',
+ 'kml' => 'application/vnd.google-earth.kml+xml',
+ 'kmz' => 'application/vnd.google-earth.kmz',
+ 'lyx' => 'application/x-lyx',
+ 'm3u' => 'text/plain',
+ 'm3u8' => 'text/plain',
+ 'mathml' => 'application/mathml+xml',
+ 'mbtiles' => 'application/x-sqlite3',
+ 'md' => 'text/x-markdown',
+ 'pas' => 'text/x-pascal',
+ 'pdf' => 'application/pdf',
+ 'pgn' => 'application/x-chess-pgn',
+ 'pls' => 'text/plain',
+ 'ppt' => 'application/vnd.ms-powerpoint',
+ 'pot' => 'application/vnd.ms-powerpoint',
+ 'ps' => 'application/postscript',
+ 'psd' => 'image/x-photoshop', // pas enregistre par IANA
+ 'rar' => 'application/x-rar-compressed',
+ 'rdf' => 'application/rdf+xml',
+ 'ris' => 'application/x-research-info-systems',
+ 'rpm' => 'application/x-redhat-package-manager',
+ 'rtf' => 'application/rtf',
+ 'sdc' => 'application/vnd.stardivision.calc',
+ 'sdd' => 'application/vnd.stardivision.impress',
+ 'sdw' => 'application/vnd.stardivision.writer',
+ 'sit' => 'application/x-stuffit',
+ 'sla' => 'application/x-scribus',
+ 'srt' => 'text/plain',
+ 'ssa' => 'text/plain',
+ 'sxc' => 'application/vnd.sun.xml.calc',
+ 'sxi' => 'application/vnd.sun.xml.impress',
+ 'sxw' => 'application/vnd.sun.xml.writer',
+ 'tar' => 'application/x-tar',
+ 'tex' => 'text/x-tex',
+ 'tgz' => 'application/x-gtar',
+ 'torrent' => 'application/x-bittorrent',
+ 'ttf' => 'application/x-font-ttf',
+ 'txt' => 'text/plain',
+ 'usf' => 'application/xml',
+ 'vcf' => 'text/vcard',
+ 'xcf' => 'application/x-xcf',
+ 'xls' => 'application/vnd.ms-excel',
+ 'xlt' => 'application/vnd.ms-excel',
+ 'wmf' => 'image/x-emf',
+ 'wpl' => 'application/vnd.ms-wpl',
+ 'xspf' => 'application/xspf+xml',
+ 'xml' => 'application/xml',
+ 'yaml' => 'text/yaml',
+ 'zip' => 'application/zip',
+
+ // Open Document format
+ 'odt' => 'application/vnd.oasis.opendocument.text',
+ 'ods' => 'application/vnd.oasis.opendocument.spreadsheet',
+ 'odp' => 'application/vnd.oasis.opendocument.presentation',
+ 'odg' => 'application/vnd.oasis.opendocument.graphics',
+ 'odc' => 'application/vnd.oasis.opendocument.chart',
+ 'odf' => 'application/vnd.oasis.opendocument.formula',
+ 'odb' => 'application/vnd.oasis.opendocument.database',
+ 'odi' => 'application/vnd.oasis.opendocument.image',
+ 'odm' => 'application/vnd.oasis.opendocument.text-master',
+ 'ott' => 'application/vnd.oasis.opendocument.text-template',
+ 'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',
+ 'otp' => 'application/vnd.oasis.opendocument.presentation-template',
+ 'otg' => 'application/vnd.oasis.opendocument.graphics-template',
+
+ 'cls' => 'text/x-tex',
+ 'sty' => 'text/x-tex',
+
+ // Open XML File Formats
+ 'docm' => 'application/vnd.ms-word.document.macroEnabled.12',
+ 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
+ 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12',
+ 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template',
+
+ 'potm' => 'application/vnd.ms-powerpoint.template.macroEnabled.12',
+ 'potx' => 'application/vnd.openxmlformats-officedocument.presentationml.template',
+ 'ppam' => 'application/vnd.ms-powerpoint.addin.macroEnabled.12',
+ 'ppsm' => 'application/vnd.ms-powerpoint.slideshow.macroEnabled.12',
+ 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
+ 'pptm' => 'application/vnd.ms-powerpoint.presentation.macroEnabled.12',
+ 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
+
+ 'xlam' => 'application/vnd.ms-excel.addin.macroEnabled.12',
+ 'xlsb' => 'application/vnd.ms-excel.sheet.binary.macroEnabled.12',
+ 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12',
+ 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
+ 'xltm' => 'application/vnd.ms-excel.template.macroEnabled.12',
+ 'xltx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.template'
+);
+
+
+$mime_alias = array(
+ 'application/x-ogg' => 'application/ogg',
+ 'audio/3gpp' => 'video/3gpp',
+ 'audio/x-mpeg' => 'audio/mpeg',
+ 'audio/x-musepack' => 'audio/musepack',
+ 'audio/webm' => 'video/webm',
+ 'video/flv' => 'video/x-flv',
+ 'video/mp4' => 'application/mp4',
+ 'image/jpg' => 'image/jpeg'
+);