首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > XML SOAP >

Unrecognized attribute 'xmlns'解决方法

2012-08-28 
Unrecognized attribute xmlns解决办法SymptomsWhen using VS.NET Web Developer Express Edition, you

Unrecognized attribute 'xmlns'解决办法

Symptoms
When using VS.NET Web Developer Express Edition, you may have a site that compiles fine in the development environment but fails when you copy it to the local IIS server.

Cause
ASP.NET 2.0 is not the default .NET version used by IIS.? It works in the development environment because VS.NET compiles a virtual web server with the proper .NET version before code compilation begins.

Thinking it occurred because the virtual directory wasn't identified as an application, I created a site (called personal) that mapped to the directory I copied, but still failed.

As it turns out, 'xmlns' is a component in ASP.NET 2.0, and will generate that error when compiled on an IIS server running ASP.NET 1.1.? This is delightfully easy to fix:

Open Internet Information Services and navigate to "Default Web Site" (or the site you're using as your default). Right click the Site icon (the one with the globe). Select the ASP.NET tab.? You'll see a drop-down with the available versions (if you're getting the error, odds are, you'll see 1.1). Select the proper build of ASP.NET 2.0. Restart IIS.

Your page should now work.

热点排行