mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-07-31 19:06:34 +08:00
#19893: Mime types are not read from the local web.config
Work Item: 19893 --HG-- branch : 1.x
This commit is contained in:
parent
4d576e9ef0
commit
6e7249f257
@ -29,8 +29,9 @@ namespace Orchard.FileSystems.Media {
|
||||
return _cacheManager.Get(extension, ctx => {
|
||||
try {
|
||||
try {
|
||||
|
||||
string applicationHost = System.Environment.ExpandEnvironmentVariables(@"%windir%\system32\inetsrv\config\applicationHost.config");
|
||||
string webConfig = System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration(null).FilePath;
|
||||
string webConfig = System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration("~").FilePath;
|
||||
|
||||
// search for custom mime types in web.config and applicationhost.config
|
||||
foreach (var configFile in new[] { webConfig, applicationHost }) {
|
||||
|
Loading…
Reference in New Issue
Block a user