I have figured out how to add a url redirect for my entire site to a maint.html page on one site away from our servers to another site of mine that is somewhere else....by going into the IIS console and setting it up there via the console interface.
But when I have to do the maintenance, I need to do it on 8 or 10 sites.
It's slow going into the IIS console and wandering around in there to turn on these redirects.
I am guessing this can be done from a command line ... but I need some help with that.
Here is what ended up in my web.config on one of them... (domain is changed)
<httpRedirect enabled="true" destination="http://www.my-other-domain.com/maint.html
" exactDestination="true" />
So, is there a way to issue this from a command line?
For example, if I have three sites: www.mysite-one.com www.mysite-two.com www.mysite-three.com
Say I wanted these three websites to redirect all requests to http://www.my-other-domain.com/maint.html
Can I do this from the command line?
And, I have a fourth site that I only want to redirect one virtual directory on it ..
So, I need to redirect all requests on www.mysite-four.com/virtualdir/
also to http://www.my-other-domain.com/maint.html
Thx Scott :-)