How to scrape the first paragraph from a wikipedia page?
Posted
by David
on Stack Overflow
See other posts from Stack Overflow
or by David
Published on 2010-05-10T01:33:39Z
Indexed on
2010/05/10
1:58 UTC
Read the original article
Hit count: 338
Let's say I want to grab the first paragraph in this wikipedia page. How do I get the principal text between the title and contents box using XPath or DOM & PHP or something similar?
Is there any php library for that? I don't want to use the api because it's a bit complex.
Note: i just need that to add a widget under my pages that displays related info from Wikipedia.
© Stack Overflow or respective owner