12 |
|
|
13 |
#----------------------------------------------------------------------------- |
#----------------------------------------------------------------------------- |
14 |
# $Log$ |
# $Log$ |
15 |
|
# Revision 1.8 2004/08/31 16:48:19 joko |
16 |
|
# + def authenticate |
17 |
|
# |
18 |
# Revision 1.7 2004/08/31 09:34:10 joko |
# Revision 1.7 2004/08/31 09:34:10 joko |
19 |
# + def query_remote: don't do "getTopicById" here anymore |
# + def query_remote: don't do "getTopicById" here anymore |
20 |
# |
# |
161 |
except Error, v: |
except Error, v: |
162 |
print "ERROR", v |
print "ERROR", v |
163 |
return topicdata |
return topicdata |
164 |
|
|
165 |
|
def authenticate(self, server, username, password): |
166 |
|
from xmlrpclib import Server, Error |
167 |
|
rpc = Server(server) |
168 |
|
try: |
169 |
|
return rpc.authenticate({'user': username, 'pass': password}) |
170 |
|
except Error, v: |
171 |
|
print "ERROR", v |
172 |
|
|
173 |
|
|
174 |
class urlOpener(object): |
class urlOpener(object): |
175 |
"""Opens urls.""" |
"""Opens urls.""" |