如题:
系统是2000.程序在2003下运行没问题.
首页中放置了个搜索新闻的东西.
访问地址是http://localhost/时,每次点搜索时就出现"HTTP 405 - 资源被禁止"
但是输入直接的地址:http://localhost/index.aspx时就没有问题.
权限设置过了.就是不知道为什么没有直接输入所在的网址网页就有这种问题发生??

解决方案 »

  1.   

    试下在IIS中修改该网站的权限,
    IIS中该网站文件的属性->执行权限,权限设置一下,把"无"改成其他两种
      

  2.   

    不行.好像没什么用.就是一个是直接输入页面的地址.一个没输入如
    http://localhost/
    http://localhost/index.aspx
    其实这两个文件都一样.但是我提交搜索时就一个出现"HTTP 405 - 资源被禁止"一个正常..郁闷啊~~是不是2000就有这个问题?我在2003都不会有这种问题
      

  3.   

    可能是你的网站禁用了目录浏览,可以在属性-》文档-》启用默认文档的下面添加 index.aspx
      

  4.   

    IIS->默认网站->你所做网站文件的属性->弹出的属性框 "目录"选项卡->执行权限
    你所说的问题应该是这个问题
      

  5.   

    net_lover(【孟子E章】) ( ) 信誉:875 2007-3-7 20:45:50 得分:40 
     
     

    这是因为iis里没有.htm的映射,默认只允许get.要 post,则按照下面的做法添加映射Go to "Control Panel"-"Administrative Tools"-"Internet Information Services". 
    Expand the tree to "COMPUTERNAME"-"Web Sites"-"Default Web Site". 
    Right-click on "Default Web Site" and select "Properties". (Alternately, select "Default Web Site" and press Alt+Enter.) 
    Select the "Home Directory" tab. 
    Click the "Configuration" button. 
    From the "Mappings" tab, select the "Add" button. 
    Click the "Browse..." button, choose "Dynamic Link Libraries *.dll" from the "Files of Type" dropdown, and select c:\WINDOWS\System32\inetsrv\asp.dll. 
    Type ".html" (without quotes) in the "Extension" box. 
    Select the "Limit to:" radio button, and type in "GET, POST" (without quotes) in the box next to it. 
    Click the "OK" button and close all the dialogs. (If the "OK" button is greyed out, then make sure all the entries are correct and try clicking in the file name box.) 
    参见
    http://www.somacon.com/p126.php
     
     
      

  6.   

    "是因为iis里没有.htm的映射,默认只允许get.要 post,则按照下面的做法添加映射"
    请问这个的作用是什么?
    我用的是.ASPX的文件.需要.HTM的映射吗?
    还有.我之前所说的
    http://localhost/
    http://localhost/index.aspx
    这两个都是同一个文件.结果使用http://localhost/这个时.查询出来的结果就是"HTTP 405 - 资源被禁止"
    如果我是使用http://localhost/index.aspx查询出来的结果是没有问题的.
    我在WIN2003系统下执行两个都没有问题.在2000下就出了这个问题.