Re: How to get all links from a webpage?

From: Date: Sun, 25 Jul 2004 11:44:07 +0000
Subject: Re: How to get all links from a webpage?
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-191807@lists.php.net to get a copy of this message
Wudi wrote:
This script can replace links:
    $text = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]", "<a href=\"\\0\">\\0</a>", $text);
But it cannot get the links.
Magic 8-ball says... go read ereg() in your manual.

« previous php.general (#191807) next »