IIS:将所有请求重定向到一个页面? [英] IIS: Redirect ALL requests to one page?

查看:511
本文介绍了IIS:将所有请求重定向到一个页面?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于我的IIS网站,我想将所有请求重定向到一个页面。这样做的目的是我想对我的所有Web应用程序使用的数据库(离线)进行一些维护。我在这个网站上运行了大约50个网络应用程序,因此我想避免访问每个应用程序以更改某些内容。我想我可以在machine.config中进行一次更改?任何提示都将不胜感激。

For my IIS website, I'd like to redirect ALL requests to ONE page. The purpose of this is that I want to do some maintenance on the database (take it off-line) that all my web applications use. I have about 50 web apps running under this website, so I'd like to avoid visiting each of them to change something. I'm thinking I could make a single change in machine.config? Any hints would be appreciated.

推荐答案

如果您使用的是ASP.NET 2.0(或更高版本),则可以删除app_offline。根目录上的htm页面。

If you are using ASP.NET 2.0 (or higher), you can drop an app_offline.htm page on the root.

此处有更多信息

这篇关于IIS:将所有请求重定向到一个页面?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆