All Questions

1784
votes
28answers
341443 views

How do you parse and process HTML/XML in PHP?

How can one parse HTML/XML and extract information from it?
175
votes
18answers
48439 views

Using regular expressions to parse HTML: why not?

It seems like every question on stackoverflow where the asker is using regex to grab some information from HTML will inevitably have an "answer" that says not to use regex to parse HTML. Why not? I'm...
139
votes
0answers
49133 views

Robust and Mature HTML Parser for PHP

Are there any robust and mature HTML parsers available for PHP? A quick skimming of PEAR didn't turn anything up (lots of classes for generating HTML, not so much for consuming), and Google taught me ...
129
votes
21answers
276564 views

How to extract img src, title and alt from html using php?

I would like to create a page where all images which reside on my website are listed with title and alternative representation. I already wrote me a little program to find and load all HTML files, bu...
56
votes
0answers
9176 views

How to parse HTML with PHP?

Possible Duplicate: How to parse and process HTML with PHP? Suggestion for a reference question. Stack Overflow has dozens of "How to parse HTML" questions coming in every day. However,...
371
votes
40answers
161541 views

Options for HTML scraping?

I'm thinking of trying Beautiful Soup, a Python package for HTML scraping. Are there any other HTML scraping packages I should be looking at? Python is not a requirement, I'm actually interested in he...
140
votes
7answers
208069 views

Parse a HTML String with JS

I searched for a solution but nothing was relevant, so here is my problem: I want to parse a String which contains HTML text. I want to do it in JavaScript language. I tried this library: http://ejoh...
157
votes
3answers
146606 views

Which HTML Parser is the best?

I code a lot of parsers. Up until now, I was using HtmlUnit headless browser for parsing and browser automation. Now, I want to separate both the tasks. As 80% of my work involves just parsing, I wa...
24
votes
2answers
15167 views

DOMDocument in php

I have just started reading documentation and examples about DOM, in order to crawl and parse the document. For example I have part of document shown below: <div id="showContent"> <...
69
votes
29answers
26304 views

Can you provide examples of parsing HTML?

How do you parse HTML with a variety of languages and parsing libraries? When answering: Individual comments will be linked to in answers to questions about how to parse HTML with regexes as a wa...

Previous Next