Diferencia entre revisiones de «LSWC scraping the web/taller scraping lwsc 2011»
De WikiEducator
| Línea 21: | Línea 21: | ||
TOCdepth=2| | TOCdepth=2| | ||
Title=Lectura básica de un documento| | Title=Lectura básica de un documento| | ||
| + | <source lang="python" line="GESHI_NORMAL_LINE_NUMBERS" > | ||
| + | from amara.bindery import html | ||
| + | URL = 'http://mypage.com' | ||
| + | |||
| + | doc = html.parse(URL) | ||
| + | |||
}} | }} | ||
Revisión de 14:21 6 nov 2011
Actividad
Configuración del entorno
$ sudo pip install http://files.akara.info/00-amara-latest.tar.bz2 Tip: Es necesario tener instalado un compilador de C y la cabeceras de python (en debian/ubuntu hay que instalar python-dev)
|
{{Actividad| TOCdepth=2| Title=Lectura básica de un documento|
from amara.bindery import html
URL = 'http://mypage.com'
doc = html.parse(URL)
}}