Python urllib2 accesses page without sending authentication details -
i reading urllib2
tutorial wherein mentions in order access page requires authentication (e.g. valid username , password), server first sends http
header error code 401 , (python) client sends request authentication details.
now, problem in case there exist 2 different versions of webpage, 1 can accessed without supplying authentication details , 1 quite different when authentication details supplied (i.e. when user logged in system). example think url www.gmail.com, when not logged in log-in page, if browser remembers last login result email account homepage inbox displayed.
i follow details set handler
authentication , install opener
. everytime request page version of webpage not have user logged-in.
how can access other version of webpage has user logged-in?
requests makes easy. creators say:
python’s standard urllib2 module provides of http capabilities need, api thoroughly broken.
Comments
Post a Comment