开发者

problem in running website from IIS

I have pasted my website's folder in wwwroot folder of IIS. now when I try to access default page of my website from Mozilla Firefox I get the following exception.

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: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:

Line 58: ASP.NET to identify an incoming user. Line 59: --> Line 60: Line 61:

Line 62:

Source File: c:\inetpub\wwwroot\akmailnew1\web.config Line: 60

please help.


This is a very common problem for new .NET web developers. This is how I do it on XP Pro but should be similar for other OSs too. Hope this helps.

  • Settings>control panel>administrative tools>Internet Information Services
  • Find your default web site (or where ever you want the vDir)
  • Right-click>New>New Virtual Directory

From here, you will need to create an alias (usually the same as the root folder for the new site) then put in the path for the site.

Then you should be able to access the site http://[your server]/[alias]/[mainpage].aspx


Create a virtual directory. You can do this by going into the project properties window in VS and selecting the Web tab. This works for Web application projects, so I'm guessing that it will work for the Web site as well.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜