C# MSCaptcha don';t在集成MVC和Webform项目的子文件夹中工作

C# MSCaptcha don';t在集成MVC和Webform项目的子文件夹中工作,c#,asp.net,model-view-controller,webforms,C#,Asp.net,Model View Controller,Webforms,我有一个集成了MVC和Webform的项目。MScaptch在根目录中的aspx中工作正常,但在内部文件夹中的aspx文件中不工作 常见问题解答.aspx-->root----Mscaptcha就可以了 BranchPortal/Faq.aspx-->Mscaptcha不在这里工作。 My Web.config代码: <system.web> <httpHandlers> <remove verb="GET" path="CaptchaImage

我有一个集成了MVC和Webform的项目。MScaptch在根目录中的aspx中工作正常,但在内部文件夹中的aspx文件中不工作

常见问题解答.aspx-->root----Mscaptcha就可以了

BranchPortal/Faq.aspx-->Mscaptcha不在这里工作。

My Web.config代码:

<system.web>    
<httpHandlers>
      <remove verb="GET" path="CaptchaImage.axd" />
      <add verb="GET" path="CaptchaImage.axd" type="MSCaptcha.CaptchaImageHandler,MSCaptcha"/>
.
.
.
.
<system.webServer>
<handlers >
      <remove name="CAPTCHAHandler" />
      <add name="CAPTCHAHandler" verb="GET" path="CaptchaImage.axd" type="MSCaptcha.CaptchaImageHandler,MSCaptcha" />

----->错误:404(未找到)

根是可以的


对不起,英语不好

我通过添加以下行找到了解决方案:

routes.IgnoreRoute(“BranchPortal/{resource}.axd/{*pathInfo}”)

public static void RegisterRoutes(RouteCollection routes)
        {
            routes.IgnoreRoute("{resource}.aspx/{*pathInfo}");
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
            routes.IgnoreRoute("BranchPortal/{resource}.axd/{*pathInfo}");