在我的c#.net项目中调用HTML页面 [英] calling a HTML page in my c#.net project
本文介绍了在我的c#.net项目中调用HTML页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如果我在c#.net项目中调用HTML页面,那么它会被asp.net引擎解析吗?如果是,为什么?
抱歉,但我给了一个想法,但没有成功.请帮忙.
If I call a HTML page in my c#.net project, would it be parsed by the asp.net engine? If yes, why?
Sorry but I gave it a thought but didn''t get the success. Please help.
推荐答案
如果您调用(重定向或请求)在IIS
托管的Asp.net
应用程序中的HTML
页面,则请求不会由Asp.net
引擎处理.通常,IIS
处理对*.htm
或*.html
的请求(以及一些其他扩展名),并且,如果希望Asp.ne
t引擎处理对HTML
页的请求,则必须配置一些设置在IIS
中(这样,任何具有*.html
扩展名的URL都将映射到Asp.net
执行引擎),并且您还需要在Asp.net
应用程序中创建一个HTTP handler
.
If you call (Redirect or Request to) anHTML
page in anAsp.net
application hosted inIIS
, the request will not be processed byAsp.net
engine. Normally,IIS
processes the requests for*.htm
or*.html
(Along with some other extensions), and, if you wantAsp.ne
t engine to process the request forHTML
page, you have to configure some settings inIIS
(So that, any URL having*.html
extension is mapped toAsp.net
execution engine) and also you need to create anHTTP handler
in yourAsp.net
application.
这篇关于在我的c#.net项目中调用HTML页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文