I believe you have to set the cookie returned by your login
as your browser cookie. Basically, since CFHTTP does not natively
support cookies, you have to parse the cookie value out of the HTTP
header. Once you have the cookie, you can pass it back in for all
of your subsequent CFHTTP calls, thus allowing you to maintin
session state on the server.
You code does this:
------------------------------------------
1) CFHTTP to server to log into. Parse out cookie
2) Send login request along with cookie value. Parse out new
cookie
3) Now the session associated with your cookie value is
logged into the site
You need to do this:
-----------------------------------------------------------
4) Set the client cookie to be the "logged in" cookie value
from (2)
The problem I think you might have is that I think you can
only set cookies for YourDomain.com, not DomainToLogInto.com. So if
you are trying to log into a script on another domain, you might
not be able to perform (4). Someone with better knowledge of HTTP
and cookie behavior can probably add some clarification to this.