Location: PHPKode > projects > Free Blog Creator > freeblog/junction3.php
<?php
$Log=@file(dirname(__FILE__)."/log/basic.cgi");
$line=explode(",",$Log[0]);
$httphost=$line[0];
?>
<?php
$updir = dirname(__FILE__)."/log/comment/";
$dir_file = opendir( $updir );
while (false !== ($file_name = readdir($dir_file))) {
if(is_file("$updir/$file_name") && $file_name != "." && $file_name != ".."){
$dirlist[]=$file_name;
}        
}
closedir( $dir_file );

for($i=sizeof($dirlist)-1;$i>=0;$i--){
$Log=@file(dirname(__FILE__)."/log/comment/$dirlist[$i]");
for($i2=0;$i2<sizeof($Log);$i2++){
$line=explode("<>",$Log[$i2]);

if( $haba2 < 5 ){

$sid=$line[1];
$text=$line[7];

$dump = strlen($text);
if( $dump > 12 ){
$text = substr($text, 0, 12);
$text = substr($text , 0, strrpos($text , " "));
$text .="...";
}
$type3 .= "<a href=\"".$httphost."?sid=$sid#comment\">$text</a><br />\n";
}

$haba2++;
}

}
?>
<?=$type3?>
Return current item: Free Blog Creator