script to login and run command

M

Mike Brearley

How can I run a script that will log into a website and launch a specific
url on that site that executes a command to update stats?

Basically, right now I have to log into the site manually, go to the stats
page and click update now. I have the url for the update now link and if
I'm logged into the site and I put that url in my browser it runs the
update. But I'd like to set up a script that will do this for me.

The site uses asp for the login process.

--
Posted 'as is'. If there are any spelling and/or grammar mistakes, they
were a direct result of my fingers and brain not being synchronized or my
lack of caffeine.

Mike Brearley
 
M

Mike Brearley

Well, I found out the url that launches an update doesn't require a login so
I was just able to use the following, any comments on a better way to do
what I'm doing in the script?

-----------------------
Dim objExp
set objExp = CreateObject("InternetExplorer.Application")

objExp.Navigate
"http://myhostserver/stats/awstats.pl?config=mydomain&update=1"
objExp.Visible = 0

Do Until objExp.Busy = false
WScript.Sleep 10000
Loop

set objExp = Nothing
-----------------------

--
Posted 'as is'. If there are any spelling and/or grammar mistakes, they
were a direct result of my fingers and brain not being synchronized or my
lack of caffeine.

Mike Brearley
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,175
Latest member
Vinay Kumar_ Nevatia
Top