Re: List all links from a webpage
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.php archive

Re: List all links from a webpage

From: Robertico <Robertico@nomail.notvalid>
Date: Mon Sep 05 2005 - 23:59:22 CEST

> <?php
> $url = 'http://tobyinkster.co.uk';
> $n = 12 + strlen(`lynx -dump -number_links -nolist '$url'`);
> $list = substr(`lynx -dump -number_links '$url'`, $n);
> print "<pre>$list</pre>";
> ?>

I tried to remove the numbers (removed -number_links) but it doesn't work.
I 'd like to store the results in a database.
Can you explain why adding 12 to the string length ?

Robertico
Received on Mon Oct 24 02:09:45 2005