第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

使用inheritInChildApplications避免子Web應用程序中的web.config

使用inheritInChildApplications避免子Web應用程序中的web.config

慕碼人8056858 2019-08-26 11:11:30
使用inheritInChildApplications避免子Web應用程序中的web.config繼承我想補充一下<location inheritInChildApplications="false">到我的父Web應用程序的web.config但它似乎沒有工作。我的父母web.config有:<configuration>     <configSections>     </configSections>     // 10 or so custom config sections like log4net, hibernate,    <connectionStrings>     </connectionStrings>     <appSettings>     </appSettings>     <system.diagnostics>     </system.diagnostics>     <system.web>          <webParts>          </webParts>          <membership>          </membership>          <compilation>          </compilation>     </system.web>     <location ..>     <system.web>         </system.web>     </location>     <system.webServer>     </system.webServer>我的子Web應用程序在IIS中設置為應用程序,并且繼承了web.config導致問題的父級應用程序。我應該在哪里放置<location inheritInChildApplications="false">所以它忽略了所有各種web.config設置?
查看完整描述

3 回答

?
慕標5832272

TA貢獻1966條經(jīng)驗 獲得超4個贊

正如前面提到的答案的評論者所說,你不能簡單地添加這一行......

<location path="." inheritInChildApplications="false">

......就在下面<configuration>。相反,您需要包裝要禁用繼承的各個web.config節(jié)。例如:

<!-- disable inheritance for the connectionStrings section --><location path="." inheritInChildApplications="false">
   <connectionStrings>
   </connectionStrings></location><!-- leave inheritance enabled for appSettings --><appSettings></appSettings><!-- disable inheritance for the system.web section --><location path="." inheritInChildApplications="false">
   <system.web>
        <webParts>
        </webParts>
        <membership>
        </membership>

        <compilation>
        </compilation>
      </system.web>
 </location>

雖然<clear />可能適用于某些配置部分,但有些部分需要<remove name="...">指令,而其他部分似乎也不支持。在這些情況下,可能適合設置inheritInChildApplications="false"。


查看完整回答
反對 回復 2019-08-26
  • 3 回答
  • 0 關(guān)注
  • 1408 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學習伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號