added mime type for mp3

This commit is contained in:
coderaiser 2012-07-31 06:20:52 -04:00
parent 647867a010
commit b06848b026
2 changed files with 13 additions and 8 deletions

View file

@ -53,7 +53,10 @@ CloudCommander.keyBinding=(function(){
}catch(error){console.log(error);}
}
/* if f3 pressed */
/* if f2 pressed */
else if(event.keyCode===113){
}
else if(event.keyCode===114){
if (typeof CloudCommander.Viewer === 'function')
CloudCommander.Viewer();

View file

@ -202,22 +202,24 @@ CloudServer.generateHeaders = function(pName, pGzip){
* загружаем стили
*/
if(CloudFunc.checkExtension(pName,'css'))
lType='text/css';
lType = 'text/css';
/* загружаем js */
else if(CloudFunc.checkExtension(pName,'js'))
lType='text/javascript';
lType = 'text/javascript';
/* загружаем картинки*/
else if(CloudFunc.checkExtension(pName,'png'))
lType='image/png';
lType = 'image/png';
/* загружаем json*/
else if(CloudFunc.checkExtension(pName,'json'))
lType='application/json';
lType = 'application/json';
else if(CloudFunc.checkExtension(pName,'html'))
lType='text/html';
lType = 'text/html';
else if(CloudFunc.checkExtension(pName,'woff'))
lType='font/woff';
lType = 'font/woff';
else if(CloudFunc.checkExtension(pName,'appcache'))
lType='text/cache-manifest';
lType = 'text/cache-manifest';
else if(CloudFunc.checkExtension(pName,'mp3'))
lType = 'audio/mpeg';
/* если это неизвестный тип файла -
* высылаем его просто как текст
*/