We are excited to announce that the IIS.NET Forums are moving to the new Microsoft Q&A experience. Learn more >

can i turn off ASP? [Answered]RSS

7 replies

Last post Oct 21, 2008 04:16 AM by gancuimian

  • can i turn off ASP?

    Oct 18, 2008 08:23 AM|gancuimian|LINK

    I developed a application with classic ASP. When I was using IIS6, I can turn off the ASP execution on some folder. When I am using IIS7 and I installed the ASP, it executes well, but how can i turn off the execution privilege on speicified folder in my site? Thanks.

  • Re: can i turn off ASP?

    Oct 18, 2008 08:48 AM|steve schofield|LINK

    Try removing the ASP script mapping on the particular folder or virtual directory.

    Steve Schofield
    Windows Server MVP - IIS
    http://iislogs.com/steveschofield
    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget

  • Re: can i turn off ASP?

    Oct 18, 2008 08:53 AM|gancuimian|LINK

    steve schofield

    Try removing the ASP script mapping on the particular folder or virtual directory.

    Thanks, but how can I remove it? I can't find this option in my IIS Manager.

  • Re: can i turn off ASP?

    Oct 18, 2008 07:54 PM|steve schofield|LINK

    If this is a virtual directory marked as application, you can remove the script mapping, otherwise the only other place it would be at is the root folder, which would turn off asp for the entire site.    Be careful as making changes to the wrong script mapping can effect other mappings. Hope that helps.

    • <div mce_keep="true">Start, </div>
    • <div mce_keep="true">Run, </div>
    • <div mce_keep="true">InetMgr, Navigate to your site.</div>
    • <div mce_keep="true">Right Click on the virtual directory, </div>
    • <div mce_keep="true">Select properties,</div>
    • <div mce_keep="true">Click the Configuration button on the virtual directory tab</div>
    • <div mce_keep="true">Scroll down to the ASP script mapping  
       </div>
    • <div mce_keep="true">www.iislogs.com/images/script1.jpg</div>
    • <div mce_keep="true">www.iislogs.com/images/script2.jpg

      </div>

    Steve Schofield
    Windows Server MVP - IIS
    http://iislogs.com/steveschofield
    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget

  • Re: can i turn off ASP?

    Oct 18, 2008 10:25 PM|gancuimian|LINK

    steve schofield

    If this is a virtual directory marked as application, you can remove the script mapping, otherwise the only other place it would be at is the root folder, which would turn off asp for the entire site.    Be careful as making changes to the wrong script mapping can effect other mappings. Hope that helps.

    • <div>Start, </div>
    • <div>Run, </div>
    • <div>InetMgr, Navigate to your site.</div>
    • <div>Right Click on the virtual directory, </div>
    • <div>Select properties,</div>
    • <div>Click the Configuration button on the virtual directory tab</div>
    • <div>Scroll down to the ASP script mapping  
       </div>
    • <div>www.iislogs.com/images/script1.jpg</div>
    • <div>www.iislogs.com/images/script2.jpg

      </div>

     

    Thank you! I find the application mapping in IIS7 Manager, throw click the folder I want to disable asp, and enter application mapping in the center panel(I can't find properties menu item with right click in IIS7 mamager under my Vista business). And I simply deleted the ASP item in the application mapping, and the ASP file in that folder functions just like a general file that can be downloaded without execution that is just what I want.

    Thanks again.

  • Re: can i turn off ASP?

    Oct 20, 2008 09:38 PM|steve schofield|LINK

    Ahh ok.  Inetmgr > Site Name > IIS Section > Handler Mappings > Right click Properties.  Here is a picture of the setting.  It changed in IIS 7.

    http://www.iislogs.com/images/turnoffasp.jpg

    Steve Schofield
    Windows Server MVP - IIS
    http://iislogs.com/steveschofield
    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget

  • Re: can i turn off ASP?

    Oct 20, 2008 09:47 PM|steve schofield|LINK

    I tried disabling by selecting None and it didnt' work, once I removed the ClassicASP handler all together, it worked like you are looking for.  ASP files worked at the root. I'm not sure why at the moment but I wanted to send an update.  If you ever wanted to add it back to a particular vdir, all you have to do is select Revert To Inherited.  This will inherit the parent settings, which has the ASP handler mapping.

    Steve Schofield
    Windows Server MVP - IIS
    http://iislogs.com/steveschofield
    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget

  • Re: can i turn off ASP?

    Oct 21, 2008 04:16 AM|gancuimian|LINK

    It works well now. I just removed the handle. If I disable execute, then the ASP files will not be allowed to access by user.