This article is a mirror article of machine translation, please click here to jump to the original article.

View: 19369|Reply: 1

[ASP.NET] asp.net Access to static resources in MVC routes

[Copy link]
Posted on 10/13/2016 5:09:14 PM | | | |
I want to access a static file, not to let the website find the static resource file according to the path, but to access the static resource file through routing.

Irritability... After an afternoon, first of all, the following methods can be done, but it is not advisable!

Some people write it like this, all access is routed, and it doesn't work...


Correct writing:

Definition of routing:



web.config configuration:



Be sure to add the table of contents... It's a dog, it's a real pit



Perfect solution!!




Previous:Styles.Render triggers the thought of runAllManagedModulesForAllRequests=true
Next:C# large file copying reads and writes
 Landlord| Posted on 10/13/2016 5:10:55 PM |
References http://stackoverflow.com/questions/37465346/how-to-install-asp-mvc-4-application-inside-asp-net-core-application
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com