Vuk Stanković
Vuk Stanković

Reputation: 7954

HTML parsing in Clojure

I'm looking for a good way to parse HTML in Clojure.

Exactly what I'm trying to do is get content of a web page with crawler and then get content of some HTML tags or their attributes.

So I have URL to the page, and I get html as String, but how do get data I need?

Upvotes: 5

Views: 2455

Answers (1)

Leon Grapenthin
Leon Grapenthin

Reputation: 9266

Use https://github.com/cgrand/enlive It allows you to select and retrieve with CSS-alike selectors.

Or https://github.com/nathell/clj-tagsoup

I am not experienced with tag-soup but I can tell that enlive works well for most scraping.

Upvotes: 6

Related Questions