I'm trying to login on Habbo.com/me via Python... this worked fine untill a few weeks ago. Does anyone know how to fix this? I really need it to work. It now gives me a HTTPError: HTTP Error 405: Not Allowed
- PuhekuplaCode:import urllib, urllib2 import cookielib import sys class WebLogin(object): def __init__(self): self.base_url = 'http://www.habbo.com/account/submit' self.cookies = 'login.cookies' self.username = '[USERNAME]' self.password = '[PASSW]' self.cj = cookielib.MozillaCookieJar(self.cookies) self.opener = urllib2.build_opener(urllib2.HTTPRedirectHandler(),urllib2.HTTPHandler(debuglevel=0),urllib2.HTTPSHandler(debuglevel=0),urllib2.HTTPCookieProcessor(self.cj)) self.opener.addheaders = [('User-agent', ('Mozilla/4.0 (compatible; MSIE 6.0; ''Windows NT 5.2; .NET CLR 1.1.4322)'))] response = self.opener.open(self.base_url) self.cj.save() login_data = urllib.urlencode({'credentials.username' : self.username, 'credentials.password' : self.password, 'remember_me' : True}) response = self.opener.open(self.base_url, login_data) self.cj.save() if __name__ == "__main__": WebLogin()





Reply With Quote






