Navigation :

Home
Source code
Tutorials
RSS feeds
Articles
Wordpress plugins
Blog
Books
Software
Downloads
Hosting
manuals
Script directory
Training
Our Links




Site Sponsors :

Bookmark :

Links :

gambling sites
dvd information
golfing products

Downloads :

Misc :

Webmaster Resources
Only PHP
ScriptSearch.com
Scripts.com - Get the best scripts NOW!
AndreaPHP Programming

Valid XHTML 1.0 Transitional


Valid CSS!


Find all links

Display all links on a web page

<?

$page = 0;
$URL = "http://www.beginnersphp.co.uk/";
$page = @fopen($URL, "r");
print("Links at $URL<BR>\n");
print("<UL>\n");
while(!feof($page)) {
$line = fgets($page, 255);
while(eregi("HREF=\"[^\"]*\"", $line, $match)) {
print("<LI>");
print($match[0]);
print("<BR>\n");
$replace = ereg_replace("\?", "\?", $match[0]);
$line = ereg_replace($replace, "", $line);
}
}
print("</UL>\n");
fclose($page);

?>