Пример #1
0
 def start_a(self, attrs):
       if not self.parseContent:
             return
       self.parseContent = False
       nodes = attrs2dic(attrs)
       self.url = "%s" % nodes["href"]
       self.parseTitle = True
Пример #2
0
    def start_a(self, attrs):
        if not self.parseContent:
            return

        nodes = attrs2dic(attrs)
        self.url = "%s%s" % (HOME_URL, nodes["href"])
        self.parseTitle = True
Пример #3
0
    def start_a(self, attrs):
        if not self.parseContent:
            return

        nodes = attrs2dic(attrs)
        self.url = "%s%s" % (HOME_URL, nodes["href"])
        self.parseTitle = True
Пример #4
0
 def start_a(self, attrs):
     if not self.parseContent:
         return
     self.parseContent = False
     nodes = attrs2dic(attrs)
     self.url = "%s" % nodes["href"]
     self.parseTitle = True
Пример #5
0
 def start_a(self, attrs):
       if self.hasValue:
             return
       nodes = attrs2dic(attrs)
       if "class" in nodes and nodes["class"] == "title":
             hasValue = True
             self.title = nodes["title"]
             self.url = "%s%s" % (HOME_URL, nodes["href"])
Пример #6
0
 def start_div(self, attrs):
       nodes = attrs2dic(attrs)
       if not self.hasValue and "class" in nodes and nodes["class"] == "newslist":
             self.parseContent = True
             self.hasValue = True
Пример #7
0
 def start_div(self, attrs):
     nodes = attrs2dic(attrs)
     if not self.hasValue and "class" in nodes and nodes["class"] == "item":
         self.parseContent = True
         self.hasValue = True
Пример #8
0
 def start_div(self, attrs):
       nodes = attrs2dic(attrs)
       if not self.hasValue and "class" in nodes and nodes["class"] == "post_item_body":
             self.hasValue = True
             self.parseContent = True