Client Side login and cookie script

djfurthur

Newcomer
Joined
Jun 24, 2003
Messages
10
I am trying to write a script that logs into a web site and captures the session cookie, which will be used later by and httpWebResponse object to download files. Currently, i am attempting to use a ServerXMLHttp object, which is getting me nowhere.

Here is what i have so far:

Dim xmlhttp as object
Dim temp As String
Dim sessionID As Cookie

xmlhttp = CreateObject("MSXML2.ServerXMLHTTP")
xmlhttp.Open("POST", "https://retaillink.wal-mart.com/rl_logon.aspx?ServerType=IIS1&txtUser=" & UserName & "&txtPass=" & Password, False)
'xmlhttp.setRequestHeader("Cookie", SessionID)
xmlhttp.send()

I think i need to use a setRequestHeader to get a cookie, but the response from the website gives me the login page. Any ideas from anyone who has worked out a similar problem?

thanks,
chris
 
Back
Top