Exemplo n.º 1
0
 def from_url(url, xpath=None):
   response = urllib2.urlopen(url)
   content = response.read()
   text = html.clean(content, xpath)
   return Document(text)
Exemplo n.º 2
0
 def from_html(content, xpath=None):
   text = html.clean(content, xpath)
   return Document(text)