Tfe

Ongi etorri tfe-ren webgunera...

Old stuff/Perl/xchat/old_script/urls.php

(Deskargatu)
<h1>Urls grabbed</h1>

<div class='centre'>
<?

# EDIT THIS VAR, WHERE THE liens.txt IS ...
$fichier = "/home/tfe/.xchat2/liens.txt";



$fb = fopen($fichier,"r");
$contenu = fread($fb,filesize($fichier));

$contenu = split("\n",$contenu);
$id = 0;
$contenu = array_reverse($contenu);
foreach ($contenu as $full)
{
	$url = split(" ",$full);
	$nombre = count($url);
	++$id;
	echo "<p><a href='$url[0]'>$url[0]</a> (<a href='index.php?urls_$id'>$nombre liens</a>)</p>";
	
	
	if ($query[1] and $id == $query[1]) 
		{ 
			echo "<p class='selected'>";
			
			foreach($url as $key) { echo "<a href='$key'>$key</a><br />"; }
			echo "</p>";
		}
	
}



?>


</div>