You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
1.6 KiB
31 lines
1.6 KiB
|
4 years ago
|
<?xml version="1.0" encoding="utf-8"?>
|
||
|
|
|
||
|
|
<!-- Дополнительные сведения об использовании преобразования web.config см. на странице https://go.microsoft.com/fwlink/?LinkId=125889. -->
|
||
|
|
|
||
|
|
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
|
||
|
|
<!--
|
||
|
|
В следующем примере преобразование "SetAttributes" будет изменять значение
|
||
|
|
"connectionString" с целью использования "ReleaseSQLServer", только когда
|
||
|
|
указатель "Match" находит атрибут "name", который имеет значение "MyDB".
|
||
|
|
|
||
|
|
<connectionStrings>
|
||
|
|
<add name="MyDB"
|
||
|
|
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
|
||
|
|
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
|
||
|
|
</connectionStrings>
|
||
|
|
-->
|
||
|
|
<system.web>
|
||
|
|
<!--
|
||
|
|
|
||
|
|
В следующем пример преобразование "Replace" будет заменять весь
|
||
|
|
раздел <customErrors> в файле web.config.
|
||
|
|
Заметьте, поскольку имеется только один раздел customErrors в узле
|
||
|
|
<system.web>, не требуется использовать атрибут "xdt:Locator".
|
||
|
|
|
||
|
|
<customErrors defaultRedirect="GenericError.htm"
|
||
|
|
mode="RemoteOnly" xdt:Transform="Replace">
|
||
|
|
<error statusCode="500" redirect="InternalError.htm"/>
|
||
|
|
</customErrors>
|
||
|
|
-->
|
||
|
|
</system.web>
|
||
|
|
</configuration>
|