Re: scripting a periodic iis redirect

From: Kristofer Gafvert (kgafvert_at_NEWSilopia.com)
Date: 01/13/05


Date: Thu, 13 Jan 2005 11:34:15 -0800

Hi Kevin,

Can you program? It would be quite simple to write a script or application
for this, using IIS ADSI. The property you want to change is HttpRedirect:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/iis/ref_mb_httpredirect.asp

The following webpage has some more examples using this:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/iis/redirecting_using_the_httpredirect_metabase_property.asp

I'm sorry i don't have time to help you write it right now, i just have
too much to do the coming weeks :-(

-- 
Regards,
Kristofer Gafvert
www.gafvert.info - My articles and help
www.ilopia.com
kevinL wrote:
> Sure, John, and thanks for the reply.
>
> I have a W2K, sp 4 server running IIS 5.0.2157.1.  I have "A redirect to 
a
> URL" set up to accomodate a specfic application which interacts with our
> public library catalog software.  Below is the specific "Redirect to"
>
> 
http://newport.lib.unc.edu/web2/tramp2.exe/log_in?SETTING_KEY=english&guest=guest&screen=home.html
>
> Periodically, over the last year I have needed to change the "Redirect 
to"
> in order to force library patrons using services to a customer 
satisfaction
> survey for a 10 minute period.  I go to the gui and change the "Redirect 
to"
>
> 
http://www.lib.unc.edu/survey/libuse/index.html?origin=http://newport.lib.unc.edu/web2/tramp2.exe/log_in?SETTING_KEY=english&guest=guest&screen=home.html
>
> Beginning in ~2 weeks, I need to start doing these redirects for 10 
minute
> periods during the middle of the night.  Why the middle of the night?
> Apparently, we have patrons using our digital library services from 
around
> the globe now so to get a good sample, I need to push the survey out 
randomly
> around the clock.
>
> The problem:  I can't seem to get started on the right track to automate 
and
> then schedule the change of the redirect and the reversal of same 10 
minutes
> later.  I am a relative newbie to scripting but am motivated by the few
> simple successes I have had so far using scripted solutions and I really
> don't want to wake up at 2 a.m. for a 10 minute task using the gui.
>
> Any suggestions would be greatly appreciated and I'll endeavor to repay 
the
> courtesy to the community by helping other scripting newbies down the 
road.
>
> many thanks,
>
> kevinL
>
>
>
>
>
>
>
> "John Cesta" wrote:
>
> > On Wed, 12 Jan 2005 10:07:01 -0800, kevinL
> > <kevinL@discussions.microsoft.com> wrote:
> >
> > > Periodically, I need to modify a redirect from normal function to an 
online
> > > survey for the only site hosted on a particular server running IIS 
5.0  I
> > > have been doing this with the IIS gui without probs.
> > >
> > > Beginning soon, these redirect changes will need to happen in the 
middle of
> > > the night.  Could someone help me get on the right track for 
scheduling and
> > > scripting them?  I have searched the text on the entire system for 
the text
> > > of my usual redirect and can't find it.  If I could, I would schedule
> > > changing the text and returning it to normal.  Ideas?
> > >
> > > Thanks,
> >
> > I don't get it. Can you explain this a little better?
> >
> > John Cesta
> >
> > iMAIL Reporter - Reports on iMAIL server and POP users
> > LogFileManager - IIS LogFile Management Tool
> > WebPageChecker - Helps Maintain Server UpTime
> > DomainReportIt PRO - Helps Rebuild IIS
> > http://www.serverautomationtools.com
> > >
> > > kevinL
> >
> >


Relevant Pages