mirror of
https://gitee.com/an-tao/drogon.git
synced 2024-12-02 11:47:56 +08:00
Add http file types for download
This commit is contained in:
parent
1faa4937a3
commit
5bc2929797
@ -119,6 +119,7 @@ int main()
|
||||
//api example for std::function
|
||||
drogon::HttpAppFramework::registerHttpApiMethod("/api/v1/handle4/{4}/{3}/{1}",func);
|
||||
|
||||
drogon::HttpAppFramework::instance().setDocumentRoot("./");
|
||||
//start app framework
|
||||
drogon::HttpAppFramework::instance().enableDynamicSharedLibLoading({"/tmp/views"});
|
||||
drogon::HttpAppFramework::instance().run();
|
||||
|
@ -126,7 +126,9 @@ namespace drogon
|
||||
|
||||
std::regex _apiRegex;
|
||||
bool _enableLastModify=true;
|
||||
std::set<std::string> _fileTypeSet={"html","jpg"};
|
||||
std::set<std::string> _fileTypeSet={"html","js","css","xml","xsl","txt","svg","ttf",
|
||||
"otf","woff2","woff","eot","png","jpg","jpeg",
|
||||
"gif","bmp","ico","icns"};
|
||||
std::string _rootPath=".";
|
||||
|
||||
std::atomic_bool _running;
|
||||
|
2
trantor
2
trantor
@ -1 +1 @@
|
||||
Subproject commit 992b40e7eb2a73744f56d95882bfc3cd38cdc199
|
||||
Subproject commit 46356ba273a8f7868173bd123ba1d3ced104b8d1
|
Loading…
Reference in New Issue
Block a user