Location: PHPKode > projects > Free Blog Creator > freeblog/trbcklist.php
<?php
require("header.php");
?>
Menu &gt; Manage Trackback &gt; Trackback Detail<br><br><br>

<?php
$Lid = $_GET['lid'];
$year = $_GET['year'];
if($Lid){
if($Sid){
$Log=file("./log/trackback/$year.cgi");
for($i=0;$i<sizeof($Log);$i++){
$line=explode("<>",$Log[$i]);
if($line[0]==$Lid){
$lid=$line[0];
$sid=$line[1];
$year=$line[2];
$view=$line[3];
$name=$line[4];
$email=$line[5];
$link=$line[6];
$text=$line[7];
$ip=$line[8];
break;
}
}
$text=str_replace("<br />","\n",$text);

}
?>

<?php
if(!$_POST["delete"]){
?>
<table width='400' border='0' cellpadding='4' cellspacing='1' bgcolor='#BBBBBB'>
<tr><td bgcolor='#ffffff' nowrap width='20%'>&nbsp;Date</td><td bgcolor='#ffffff'>&nbsp;<?=$view?></td></tr>
<tr><td bgcolor='#ffffff' nowrap width='20%'>&nbsp;Name</td><td bgcolor='#ffffff'>&nbsp;<?=$name?></td></tr>
<tr><td bgcolor='#ffffff' nowrap width='20%'>&nbsp;Title</td><td bgcolor='#ffffff'>&nbsp;<?=$title?></td></tr>
<tr><td bgcolor='#ffffff' nowrap width='20%'>&nbsp;URL</td><td bgcolor='#ffffff'>&nbsp;<a href='<?=$link?>' target="_blank" STYLE="color: blue;"><?=$link?></a></td></tr>
</table><br>
<table width='400'>
<?=$text?>
</table>


<table width='400'>
<td align='right'>
<form action="" method="POST">
<INPUT type='hidden' name='lid' value='<?=$lid?>'>
<INPUT type='hidden' name='year' value='<?=$year?>'>
<input type="submit" name="delete" value="Del"></form>
</td>
</table>
<?php
}
?>
<?php
if($_POST["delete"]){
$lid = $_POST["lid"];
$year = $_POST["year"];

$Log=@file("./log/trackback/$year.cgi");
for($i=0;$i<sizeof($Log);$i++){
$line=explode("<>",$Log[$i]);
if($line[0]==$lid){
array_splice($Log,$i,1);
}

}
$fp=fopen("./log/trackback/$year.cgi","w");
flock($fp, LOCK_EX);
foreach($Log as $line)fputs($fp,$line);	
fclose($fp);


print "Deleted<br><br>";
}
?>






<?php
require("footer.php");
?>
Return current item: Free Blog Creator