Picking a phrase out of a web page.
| From: | Daniel R. Anderson | Date: | Fri, 09 May 2003 14:29:13 +0000 |
| Subject: | Picking a phrase out of a web page. | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-147026@lists.php.net to get a copy of this message | ||
I am trying to write a function to parse an arbitrary web page and
extract information. As a for instance, if I file() a page on
amazon.com I want to go over each line (array element) and if it sees
Price: $xx.xx I want to pull out $xx.xx. I was thinking of a foreach
statement with strstr to test for the string, but would appreciate any
pointers anybody might be able to give.
Thanks,
-Dan Anderson