Works like a gem! Thanks a ton. ClientForm and ClientCookie are great!
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> I'm learning python, and my goal is to write a script that will log
> into a website for me. The site uses HTTPS, the form uses the "POST"
> method.
>
> >From what I've been able to find so far, it looks like i need to use
> the urllib2 module...does anyone know where I
You may find the third-party modules "ClientForm" and "ClientCookie" to
be useful.
Using ClientForm, the following code uploads a file to a particular web form:
forms = ClientForm.ParseResponse(urllib2.urlopen(url))
f = forms[0]
f.add_file(open(local, "rb"), filename=remote, name="file