开发者

In WIX, how to install WebFilter at the server level?

I know how to install a WebFilter into a particular WebSite (or Virtual Server).

How can I install a WebFilter int开发者_运维问答o the WebService - or to the top-level server?


To do this, specify no @WebSite attribute at all.

<!-- this is installed when the Server-wide install is selected for the filter -->
<Component Id='C.Filter1' Guid="YOURGUID-0556-4893-88bc-2b8ec5f3aa08">
  <Condition>WEBSITE_DESCRIPTION = "Server"</Condition>
  <!-- CreateFolder - included to avoid problem with missing KeyPath -->
  <CreateFolder/>
  <iis:WebFilter Id="IsapiFilter1"
                 LoadOrder="first"
                 Name="My ISAPI Rewriting Filter"
                 Path="[INSTALLDIR]\ISAPI.dll"
                 />
</Component>


<!-- this is installed when a particular site is selected for the filter -->
<Component Id='C.Filter2' Guid="YOURGUID-0556-4893-88bc-2b8ec5f3aa06">
  <Condition>NOT WEBSITE_DESCRIPTION = "Server"</Condition>
  <!-- CreateFolder - included to avoid problem with missing KeyPath -->
  <CreateFolder/>
  <iis:WebFilter Id="IsapiFilter2"
                 LoadOrder="first"
                 Name="My ISAPI Rewriting Filter"
                 Path="[INSTALLDIR]\ISAPI.dll"
                 WebSite='SelectedWebSite'
                 />
</Component>


<!-- snip -->

<iis:WebSite Id="SelectedWebSite" Description="[WEBSITE_DESCRIPTION]">
  <iis:WebAddress Id="AllUnassigned" Port="[WEBSITE_PORT]" IP="[WEBSITE_IP]" Header="[WEBSITE_HOSTNAME]" />
</iis:WebSite>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜