`
wtx358
  • 浏览: 26103 次
  • 性别: Icon_minigender_1
  • 来自: 广西
社区版块
存档分类
最新评论

IIS使用ISAPI_REWRITE3返回503代码

阅读更多
#for 3.x
RewriteCond %{HTTP:Host} ^.*abc\.net.*$
RewriteRule (.*) /503.asp
503.asp
<%
Response.Status="503 Service Temporarily Unavailable"
%>
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>503 Service Temporarily Unavailable</title>
</head><body>
<h1>Service Temporarily Unavailable</h1>
<p>The server is temporarily unable to service your
request due to maintenance downtime or capacity
problems. Please try again later.</p>
</body></html>
----
503.php
<?php
ob_start();
header('HTTP/1.1 503 Service Temporarily Unavailable');
header('Status: 503 Service Temporarily Unavailable');
header('Retry-After: 3600');
header('X-Powered-By:');
?>
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>503 Service Temporarily Unavailable</title>
</head><body>
<h1>Service Temporarily Unavailable</h1>
<p>The server is temporarily unable to service your
request due to maintenance downtime or capacity
problems. Please try again later.</p>
</body></html>
如果有IIS的控制权,可以为站点建一个独立的应用程序池,然后把应用程序池暂停也可以。
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics