I have some code out of my own library which kind of does this; you probably need to play with it to do exactly what you want:
preg_match_all("|<{$tag}[\s]*?>(.*?)</{$tag}[\s]*?>|si",$text,$matches); print_r($matches); Where: $tag is the tag you are looking for $text is the text string you are searching through $matches are the results of the search Cheers, Steven Balthazor -----Original Message----- From: Didier McGillis [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 29, 2003 6:24 AM To: [EMAIL PROTECTED] Subject: [PHP] hopefully easy I need to parse an HTML file for certain information. Like the text between <title></title>. So if the html was ... <html> <head> <title>The page</title> </head> <body> Lots of code ................. </body> </html> I would just like the "The page" text. _________________________________________________________________ Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php