The following forum(s) are migrating to a new home on Microsoft Q&A (Preview): Azure Virtual Machines!

Ask new questions on Microsoft Q&A (Preview).
Interact with existing posts until December 13, 2019, after which content will be closed to all new and existing posts.

Learn More

 none
ASP.NET: Adding the <location> tag to the main website web.config (in order access a sub application) causes all folders to be inaccessible. What do I have to do to make all the subdirectories accessible? RRS feed

  • Question

  • I've added an application beneath my main website which is a newer version of the main website. 
    The sub application named V2 will be used to preview changes to the main website. 

    In order to access V2 from the main website, I need to enclose both the
    <system.web> and <system.webServer> in the <location path="." inheritInChildApplications="false"> tag.

    The V2 website runs as expected (i.e. //main/V2) but all of the subfolders can't be read.  The styles and images are in folders which are inaccessible. It seems like a permission's issue.  The application is configured to allow all users full access to the root and all subdirectories.

        <authentication mode="None" />
        <
    authorization>
          <
    allow users="*" />
        </
    authorization>

    What do I have to do to make all the subdirectories accessible?

    Friday, October 11, 2019 11:18 PM

Answers

  • It's not Azure.  The platform is Windows Server 2016, and IIS 10.

    I'd suggest asking in microsoft official forums here.

    https://forums.iis.net/

    https://forums.asp.net/

     

     

     



    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows Server] Datacenter Management

    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees, and confers no rights.

    Monday, October 14, 2019 8:01 PM
    Moderator

All replies

  • Is your site being hosted on an Azure Virtual Machine? if so, are you running the site on IIS? I am just not sure how this question relates to an Azure Virtual Machine or if you are using Web Apps or something else. 
    Friday, October 11, 2019 11:36 PM
  • Hi MyFavoriteMartian,

    Can you provide the details requested by Micah?

    Monday, October 14, 2019 5:33 AM
  • It's not Azure.  The platform is Windows Server 2016, and IIS 10.

    The subfolders of the main site become unreadable when the web.config <system.webServer> tag is wrapped with the
    <location path="." inheritInChildApplications="false"> tag.
    When I toggle the inheritInChildApplications to "True" the subfolders can be read.


    Thank you for your help.

    Monday, October 14, 2019 7:18 PM
  • I moved your post to a different forum as it is not related to Azure VMs and you posted in Azure VMs. 

    You can also try posting in Stack Overflow as that is a developer site who can help with general programming related questions. 

    Monday, October 14, 2019 7:39 PM
  • It's not Azure.  The platform is Windows Server 2016, and IIS 10.

    I'd suggest asking in microsoft official forums here.

    https://forums.iis.net/

    https://forums.asp.net/

     

     

     



    Regards, Dave Patrick ....
    Microsoft Certified Professional
    Microsoft MVP [Windows Server] Datacenter Management

    Disclaimer: This posting is provided "AS IS" with no warranties or guarantees, and confers no rights.

    Monday, October 14, 2019 8:01 PM
    Moderator