<?
        $f = fopen($fileName, 'r');
        $s = fread($f, 1024);
        fclose($f);
        $pageTitle = eregi_replace('.*<title>', '',
eregi_replace('</title>.*', '', $s));
?>

> -----Original Message-----
> From: Heiko Wilms [mailto:[EMAIL PROTECTED]]
> Sent: 11 iulie 2001 13:32
> To: [EMAIL PROTECTED]
> Subject: [PHP] Getting the title of a web page
> 
> 
> Hi,
> 
> when I open a web page within my php-script with fopen(...) I 
> only want 
> to get back the title of the page. How can I do this?
> 
> Heiko
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: 
> [EMAIL PROTECTED]
> 
> 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to