actualizado el servidor HTTP

This commit is contained in:
Luis Ángel San Martín
2013-06-13 13:53:34 +02:00
parent d4ef318190
commit dee244455e
6 changed files with 25 additions and 6 deletions

View File

@ -140,6 +140,12 @@ void StaticFileController::setContentType(QString fileName, HttpResponse& respon
else if (fileName.endsWith(".html") || fileName.endsWith(".htm")) {
response.setHeader("Content-Type", qPrintable("text/html; charset="+encoding));
}
else if (fileName.endsWith(".css")) {
response.setHeader("Content-Type", "text/css");
}
else if (fileName.endsWith(".js")) {
response.setHeader("Content-Type", "text/javascript");
}
// Todo: add all of your content types
}