I think <a href="http://stackoverflow.com/questions/189555/how-to-use-python-to-login-to-a-webpage-and-retrieve-cookies-for-later-usage">this</a> could help you<br><br><div class="gmail_quote">2011/3/18 gervaz <span dir="ltr"><<a href="mailto:gervaz@gmail.com">gervaz@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">On 18 Mar, 22:52, Miki Tebeka <<a href="mailto:miki.teb...@gmail.com">miki.teb...@gmail.com</a>> wrote:<br>
> You can use mechanize, which holds a cookie jar and can user the browser cookies as well.<br>
<br>
</div>I use:<br>
opener =<br>
urllib.request.build_opener(urllib.request.HTTPCookieProcessor())<br>
urllib.request.install_opener(opener)<br>
I start scraping from <a href="http://page.com/home.html" target="_blank">http://page.com/home.html</a> that need the cookies<br>
enabled, then, once I found what I was looking for, I've got<br>
<a href="http://page.com/pageX.html" target="_blank">http://page.com/pageX.html</a> and <a href="http://page.com/pageY.html" target="_blank">http://page.com/pageY.html</a>. Those page<br>
cannot be viewed if I just copy & paste the url in the browser,<br>
because they need the cookies.<br>
<br>
What can I do?<br>
<br>
Thanks,<br>
Mattia<br>
<div><div></div><div class="h5">--<br>
<a href="http://mail.python.org/mailman/listinfo/python-list" target="_blank">http://mail.python.org/mailman/listinfo/python-list</a><br>
</div></div></blockquote></div><br>