summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar spoob <spoob@gmx.de> 2009-05-31 19:43:53 +0200
committerGravatar spoob <spoob@gmx.de> 2009-05-31 19:43:53 +0200
commitc3db22d7f10340d267bb06dadd6133841388e8de (patch)
treeb578936699e082f8f884de9bec3c5d5c2bc30957
parentBacked out changeset 9455bf89f55f made by spoob. (diff)
downloadpyload-c3db22d7f10340d267bb06dadd6133841388e8de.tar.xz
xupi.in works again
-rw-r--r--Core.py2
-rwxr-xr-xmodule/network/Request.py11
-rwxr-xr-xpyMainGui.py2
3 files changed, 10 insertions, 5 deletions
diff --git a/Core.py b/Core.py
index b4761de76..fdec3a084 100644
--- a/Core.py
+++ b/Core.py
@@ -145,7 +145,7 @@ class Core(object):
"""
newst_version = urllib2.urlopen("http://pyload.nady.biz/files/version.txt").readline().strip()
if CURRENT_VERSION < newst_version:
- print _("new update %s on pyload.de.rw") % newst_version #newer version out
+ print _("new update %s on pyload.org") % newst_version #newer version out
elif CURRENT_VERSION == newst_version:
print _("newst version %s in use:") % CURRENT_VERSION #using newst version
else:
diff --git a/module/network/Request.py b/module/network/Request.py
index 86449a4f2..196e350c9 100755
--- a/module/network/Request.py
+++ b/module/network/Request.py
@@ -90,11 +90,18 @@ class Request:
#def download(url, filename, reporthook = None, data = None): #default von urlretrieve auch None?
# return self.downloader.urlretrieve(url, filename, reporthook, data)
- def download(self, url, filename):
+ def download(self, url, filename, post = {}):
+
+ if post:
+ post = urllib.urlencode(post)
+ else:
+ post = None
+
if not self.dl:
self.dl = True
file = open(filename, 'wb')
- req = urllib2.Request(url)
+ req = urllib2.Request(url, post)
+
conn = self.downloader.open(req)
self.dl_size = int(conn.headers["content-length"])
self.dl_arrived = 0
diff --git a/pyMainGui.py b/pyMainGui.py
index 10903433c..2a51fedd5 100755
--- a/pyMainGui.py
+++ b/pyMainGui.py
@@ -115,8 +115,6 @@ class Pyload_Main_Gui(wx.Frame):
self.Bind(wx.EVT_MENU, self.exit_button_clicked, submenu_exit)
self.Bind(wx.EVT_TOOL, self.add_button_clicked, add)
-
-
self.Centre()
self.Show(True)