Пример #1
0
 def __init__(self, terms):
   self.terms = terms
   self.curRT = -1
   (res, page) = getPage(terms)
   if res == http.client.OK or res == http.client.SEE_OTHER:
     self.ddgres = xmlparser.parse_string(page)
   else:
     self.ddgres = None
Пример #2
0
 def __init__(self, terms):
   self.terms = terms
   self.curPod = 1
   self.curSubPod = 0
   (res, page) = getPage(terms)
   if res == http.client.OK:
     self.wfares = xmlparser.parse_string(page)
   else:
     self.wfares = None