2 rainkooy rainkooy 于 2014.11.18 14:16 提问

在XP上配置aspx时,出现这样的问题,该怎么办
asp

在XP上配置aspx时,出现这样的问题,该怎么办

Parser Error Message: Unrecognized attribute 'xmlns'.
Source Error:

Line 1: <?xml version="1.0" encoding="UTF-8"?>
Line 2:
Line 3:
Line 4:

Source File: c:\inetpub\wwwroot\web.config Line: 2

Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

9个回答

rainkooy
rainkooy   2014.11.18 14:17

在XP上配置aspx时,出现这样的问题,该怎么办
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Unrecognized attribute 'xmlns'.
Source Error:

Line 1: <?xml version="1.0" encoding="UTF-8"?>
Line 2:
Line 3:
Line 4:

Source File: c:\inetpub\wwwroot\web.config Line: 2

Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

rainkooy
rainkooy   2014.11.18 14:17

在XP上配置aspx时,出现这样的问题,该怎么办
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Unrecognized attribute 'xmlns'.
Source Error:

Line 1: <?xml version="1.0" encoding="UTF-8"?>
Line 2:
Line 3:
Line 4:

Source File: c:\inetpub\wwwroot\web.config Line: 2

Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

rainkooy
rainkooy   2014.11.18 14:17

Server Error in '/' Application.

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized attribute 'xmlns'.

Source Error:

Line 1: <?xml version="1.0" encoding="UTF-8"?>
Line 2:
Line 3:
Line 4:

Source File: c:\inetpub\wwwroot\web.config Line: 2


Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

showbo
showbo   Ds   Rxr 2014.11.18 14:22

记事本打开web.config,另存为看下你web.config的存储编码是不是utf-8的,如果不是选择utf-8保存试试

woshi_ziyu
woshi_ziyu   Rxr 2014.11.18 14:23

I had this problem.  When I realized that my virtual directory was set up for v1.1 of the .Net framework, the solution was simple:  go to the properties page for the application in IIS, pick the "Asp.net" tab, and change the target framework to 2.0.

Edit:

I got the solution:

  1. right click and view properties of your website in IIS.
  2. select the asp.net tab
  3. select the correct .NET version in the 'ASP .NET Version' dropdown
woshi_ziyu
woshi_ziyu   Rxr 2014.11.18 14:23

I had this problem.  When I realized that my virtual directory was set up for v1.1 of the .Net framework, the solution was simple:  go to the properties page for the application in IIS, pick the "Asp.net" tab, and change the target framework to 2.0.

Edit:

I got the solution:

  1. right click and view properties of your website in IIS.
  2. select the asp.net tab
  3. select the correct .NET version in the 'ASP .NET Version' dropdown
woshi_ziyu
woshi_ziyu   Rxr 2014.11.18 14:25

If the "ASP.Net" tab didn't show in IIS property page. We need to go to windows\microsoft.net\framework\v2.xxx\, run aspnet_iisreg -r to register all. This will ensure the ASPNet replace the old.

q107770540
q107770540   Ds   Rxr 2014.11.18 14:43

run

aspnet_regiis -i

under the VS.NET command console or from the

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727

Hope helps. Thanks,

caozhy
caozhy   Ds   Rxr 2014.11.18 15:16

it shows that current version of asp.net you used is 1.0, and you need to change to 2.0 or higher version. if you can not find that in iis manager, you should register asp.net 2.0 first.

Csdn user default icon
上传中...
上传图片
插入图片
准确详细的回答,更有利于被提问者采纳,从而获得C币。复制、灌水、广告等回答会被删除,是时候展现真正的技术了!