try the following: $text = ""; $fp = fopen("http://www.yahoo.com", "r"); while (!feof($fp)) { // read a line and strip all php and html tags // there's a third optional parameter, which // allowes to specify tags not to be replaced $text .= fgetss($fp, 4096); } fclose($fp); echo $text; "Ryan Govostes" <[EMAIL PROTECTED]> schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > The following simple code does not function: > > $html = include("http://www.yahoo.com"); > $text = strip_tags($html); > echo $text; > > I've tried several variations of the above, such as using preg_replace() > instead of strip_tags() and readfile() instead of include(), but it does > not work at all, no matter what. Does anyone know why? >
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php