| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="utf-8"?> |
| | | |
| | | <!-- For more information on using Web.config transformation visit https://go.microsoft.com/fwlink/?LinkId=301874 --> |
| | | |
| | | <configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> |
| | | <!-- |
| | | å¨ä¸ä¾ä¸ï¼âSetAttributesâ转æ¢å°æ´æ¹ |
| | | âconnectionStringâçå¼ï¼ä»
å¨âMatchâå®ä½å¨æ¾å°å¼ä¸ºâMyDBâç |
| | | ç¹æ§ânameâæ¶ä½¿ç¨âReleaseSQLServerâã |
| | | |
| | | <connectionStrings> |
| | | <add name="MyDB" |
| | | connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True" |
| | | xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/> |
| | | </connectionStrings> |
| | | --> |
| | | <system.web> |
| | | <compilation xdt:Transform="RemoveAttributes(debug)" /> |
| | | <!-- |
| | | å¨ä»¥ä¸ç¤ºä¾ä¸ï¼"Replace" 转æ¢å°æ¿æ¢ Web.config æä»¶ç |
| | | æ´ä¸ª <customErrors> èã |
| | | 请注æï¼ç±äºå¨ <system.web> èç¹ä¸åªæä¸ä¸ª |
| | | customErrors èï¼å æ¤æ éä½¿ç¨ "xdt:Locator" 屿§ã |
| | | |
| | | <customErrors defaultRedirect="GenericError.htm" |
| | | mode="RemoteOnly" xdt:Transform="Replace"> |
| | | <error statusCode="500" redirect="InternalError.htm"/> |
| | | </customErrors> |
| | | --> |
| | | </system.web> |
| | | </configuration> |