python - session error ? using POST using requests or urllib2 -



python - session error ? using POST using requests or urllib2 -

trying authenticate website , fill out form using requests lib

import requests payload = {"name":"someone", "password":"somepass", "submit":"submit"} s = requests.session() s.post("https://someurl.com", data=payload) next_payload = {"item1":"something", "item2":"something", "submit":"submit"} r = s.post("https://someurl.com", data=next_payload) print r.text

authentication works , verified can post forms 1 having problem gives the action not completed, perhaps because session had expired. please seek again attempted in urllib2 , same result -- dont think issue cookie. wondering if javascript on page has giving session error? other form page doesnt have javascripts.

thanks input...

python python-requests

Comments

Popular posts from this blog

javascript - mongodb won't find my schema method in nested container -

Hibernate criteria by a list of natural ids -

ios - Lagging ScrollView with UIWebview inside -