Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/.net/23.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 网页加载问题_C#_.net_Asp.net_Vb.net - Fatal编程技术网

C# 网页加载问题

C# 网页加载问题,c#,.net,asp.net,vb.net,C#,.net,Asp.net,Vb.net,使用ASP.Net&C# 我想在internet explorer或firefox中运行我的网页 当我运行网页时,它在VS中工作,但当我在ie中运行网页时,它显示错误为 The XML page cannot be displayed Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. ---

使用ASP.Net&C#

我想在internet explorer或firefox中运行我的网页

当我运行网页时,它在VS中工作,但当我在ie中运行网页时,它显示错误为

The XML page cannot be displayed 
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. 


--------------------------------------------------------------------------------

A name was started with an invalid character. Error processing resource 'file:///C:/Inetpub/wwwroot/Name/IIS/Detail

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="view.aspx.cs" Inherits="Default2" %>
-^
无法显示XML页面 无法使用XSL样式表查看XML输入。请更正错误,然后单击“刷新”按钮,或稍后重试。 -------------------------------------------------------------------------------- 名称以无效字符开头。处理资源“”时出错file:///C:/Inetpub/wwwroot/Name/IIS/Detail -^ 我配置了IIS,然后运行它显示的*.html文件,没有任何错误,但是*.aspx文件没有显示

*.html文件正在ie和firefox中运行,但*.aspx文件未在ie和firefox中运行


如何在internet Explorer或firefox中运行my*.aspx网页…

您正在尝试直接访问这些文件吗?那是行不通的


如果您正确配置了IIS,您应该可以浏览到
http://localhost/
,它会工作。

您的ASP.Net可能未在IIS中正确注册。
您需要从visual studio命令提示符运行aspnet_regiis-i命令。

检查windows功能,是否安装了.NET?

当您尝试在浏览器中运行aspx文件时,会出现此消息没有任何服务器端端点,或者在IIS未配置为处理ASP.NET时。ASP.NET是一种服务器端技术,这意味着服务器在收到请求时执行ASP.NET页面,并以能够理解html、xhtml、javascript等内容的方式返回输出浏览器

为什么会出现此消息?

当浏览器按原样接收asp.net文件时[未将页面呈现为html],浏览器将其视为XML文件,并且未发现asp.net页面标记是有效的XML文件,因此会出现错误

解决方案

您只需将asp.net应用程序托管在IIS中的网站或虚拟目录下,并将其配置为与asp.net一起工作,然后使用IIS中配置的asp.net页面URL从浏览器请求/运行.aspx文件


您可以找到有关如何为asp.net配置IIS的资源和信息

您可以提供使用asp.net配置的步骤来解释整个配置。过程超出了本asnwer的范围。我建议你从这里开始。