打开你的iis,默认站点--->属性--->HTTP 头--->MIME类型--->新建在扩展名里填入 .tmp
MIME类型中填入 text/plain
然后确定。好了。在support.microsoft.com中有解释,
原文如下:SYMPTOMS
When you use Visual Studio .NET 2002 to create a new Web project, and you connect to Microsoft Windows Server 2003 as the Web server, a Web Access Failed dialog box appears and you receive the following error message:The default Web access mode for this project is set to file share, but the project folder at 'http://localhost/WebApplication1' cannot be opened with the path 'c:\inetpub\wwwroot\WebApplication1'. The error returned was:Unable to create web project 'WebApplication1'. The file path 'c:\inetpub\wwwroot\WebApplication1' does not correspond to the URL 'http://localhost/WebApplication1'. The two need to map to the same server location. HTTP Error 404: Not Found
CAUSE
This problem occurs because Microsoft Internet Information Services 6.0 (IIS) blocks all file name extensions that are not explicitly mapped. By default, the .tmp file name extension is not mapped on IIS 6.0 for security reasons.During the process of creating a Web project, Visual Studio .NET 2002 tests to confirm that the URL and the UNC path match. To do this, Visual Studio .NET writes a file that has the .tmp file name extension to the server, and then requests this file from the server through an http request. Because the .tmp file name extension is not mapped on IIS 6.0, IIS returns HTTP Error 404. This causes Visual Studio .NET to return the error message described in the "Symptoms" section. Note This problem does not occur when you use Visual Studio .NET 2003 because this version uses a file that has the .htm file name extension for this process.
SYMPTOMS
When you use Visual Studio .NET 2002 to create a new Web project, and you connect to Microsoft Windows Server 2003 as the Web server, a Web Access Failed dialog box appears and you receive the following error message:The default Web access mode for this project is set to file share, but the project folder at 'http://localhost/WebApplication1' cannot be opened with the path 'c:\inetpub\wwwroot\WebApplication1'. The error returned was:Unable to create web project 'WebApplication1'. The file path 'c:\inetpub\wwwroot\WebApplication1' does not correspond to the URL 'http://localhost/WebApplication1'. The two need to map to the same server location. HTTP Error 404: Not Found
CAUSE
This problem occurs because Microsoft Internet Information Services 6.0 (IIS) blocks all file name extensions that are not explicitly mapped. By default, the .tmp file name extension is not mapped on IIS 6.0 for security reasons.During the process of creating a Web project, Visual Studio .NET 2002 tests to confirm that the URL and the UNC path match. To do this, Visual Studio .NET writes a file that has the .tmp file name extension to the server, and then requests this file from the server through an http request. Because the .tmp file name extension is not mapped on IIS 6.0, IIS returns HTTP Error 404. This causes Visual Studio .NET to return the error message described in the "Symptoms" section. Note This problem does not occur when you use Visual Studio .NET 2003 because this version uses a file that has the .htm file name extension for this process.
If security is not an issue (for example, if you are using a standalone, development computer), follow these steps to map the .tmp file name extension:
Start the Internet Information Services MMC.
Right-click your Web site, and then click Properties.
Click the HTTP Headers tab, and then click MIME Types.
Click New to add a new MIME type.
In the Extensions text box, type .tmp.
In the MIME type text box, type text/plain.
MIME类型中填入 text/plain
然后确定。好了。在support.microsoft.com中有解释,
原文如下:SYMPTOMS
When you use Visual Studio .NET 2002 to create a new Web project, and you connect to Microsoft Windows Server 2003 as the Web server, a Web Access Failed dialog box appears and you receive the following error message:The default Web access mode for this project is set to file share, but the project folder at 'http://localhost/WebApplication1' cannot be opened with the path 'c:\inetpub\wwwroot\WebApplication1'. The error returned was:Unable to create web project 'WebApplication1'. The file path 'c:\inetpub\wwwroot\WebApplication1' does not correspond to the URL 'http://localhost/WebApplication1'. The two need to map to the same server location. HTTP Error 404: Not Found
CAUSE
This problem occurs because Microsoft Internet Information Services 6.0 (IIS) blocks all file name extensions that are not explicitly mapped. By default, the .tmp file name extension is not mapped on IIS 6.0 for security reasons.During the process of creating a Web project, Visual Studio .NET 2002 tests to confirm that the URL and the UNC path match. To do this, Visual Studio .NET writes a file that has the .tmp file name extension to the server, and then requests this file from the server through an http request. Because the .tmp file name extension is not mapped on IIS 6.0, IIS returns HTTP Error 404. This causes Visual Studio .NET to return the error message described in the "Symptoms" section. Note This problem does not occur when you use Visual Studio .NET 2003 because this version uses a file that has the .htm file name extension for this process.
SYMPTOMS
When you use Visual Studio .NET 2002 to create a new Web project, and you connect to Microsoft Windows Server 2003 as the Web server, a Web Access Failed dialog box appears and you receive the following error message:The default Web access mode for this project is set to file share, but the project folder at 'http://localhost/WebApplication1' cannot be opened with the path 'c:\inetpub\wwwroot\WebApplication1'. The error returned was:Unable to create web project 'WebApplication1'. The file path 'c:\inetpub\wwwroot\WebApplication1' does not correspond to the URL 'http://localhost/WebApplication1'. The two need to map to the same server location. HTTP Error 404: Not Found
CAUSE
This problem occurs because Microsoft Internet Information Services 6.0 (IIS) blocks all file name extensions that are not explicitly mapped. By default, the .tmp file name extension is not mapped on IIS 6.0 for security reasons.During the process of creating a Web project, Visual Studio .NET 2002 tests to confirm that the URL and the UNC path match. To do this, Visual Studio .NET writes a file that has the .tmp file name extension to the server, and then requests this file from the server through an http request. Because the .tmp file name extension is not mapped on IIS 6.0, IIS returns HTTP Error 404. This causes Visual Studio .NET to return the error message described in the "Symptoms" section. Note This problem does not occur when you use Visual Studio .NET 2003 because this version uses a file that has the .htm file name extension for this process.
If security is not an issue (for example, if you are using a standalone, development computer), follow these steps to map the .tmp file name extension:
Start the Internet Information Services MMC.
Right-click your Web site, and then click Properties.
Click the HTTP Headers tab, and then click MIME Types.
Click New to add a new MIME type.
In the Extensions text box, type .tmp.
In the MIME type text box, type text/plain.
解决方案 »
- IIS 403.9
- 问个Gridview数据显示长度的问题,感觉代码没什么问题呀。。
- access 数据库 去除重复 并 以id倒序 的sql 写法
- 关于VS2008开发的MVC项目的服务器IIS设置
- [求助] 附件下载的时候,当文件名超过一定长度的时候,下载的时候出现的是aspx文件名,而不是要下载的文件名字
- 如何获取当前程序在服务器上的内存占用量?
- 关于一个页面显示的问题
- DataGrid控件的模板列中放一个panel控件。。。。。。。。
- DotTextWeb 博客怎么记录用户名,为什么不超时,谁知道用户名放到哪里了
- 谁能讲讲在什吗时候用服务器控件,什吗时候用html空间,他们的关系以及对性能的影响。
- 关于客户端问题
- 请问各位大侠,触发dropdownlist的SelectedIndexChanged事件,为何出现如下错误
我给分了,怎么显示是0分
????