<?php
// Get the search variable from URL
 	$var = @$_GET['query'] ;
	$query = trim($var);
	$var = @$_GET['count'] ;
	$cnt = trim($var);
	$var = @$_GET['search'] ;

    $count = 0;
if ($query != "")
	{
	$count = $cnt;
	}
    ?>
<html>
<head>
<title>Guestbook Comment Display</title>
</head>
<body>
<p style="text-align: center"><FONT SIZE="7"><U>View Guestbook</U></FONT></p>
<TABLE BORDER="0" WIDTH="100%" id="table2">
<TR>
	<TD WIDTH="14%" Rowspan="100" VALIGN="TOP">
	</TD>
	<TD style="padding: 40px;" WIDTH="72%" VALIGN="TOP"  Colspan="1">
<?php   $records_per_page=10;
include("Guestbook.inc");
        $query = "select name,comment,datetime from test ORDER BY datetime DESC";
require_once ("GuestbookPaging.php");
        $paginate = new paginate($conn);
        $newquery = $paginate->paging($query,$records_per_page);
        $paginate->dataview($newquery);
        $paginate->paginglink($query,$records_per_page,$count);
        $conn = Null;
{
?>
 <TD WIDTH="14%" rowspan="100" VALIGN="TOP"></td>
</TR>
</TABLE>
<?php
}
$conn = Null;
?>
 <p style="text-align: center"><span style="font-size: medium"><?php
         include("guestbook.php");
         echo '<br><br>Copyright &copy; Abbydale Systems LLC. 1997-'?>
          <?php echo date("Y");
 echo '<br><center>';
 echo '
 <p align="right"><span style="font-size: medium">';
$file = __FILE__;
$last_modified = filemtime($file);

		$lmdate = date("l, jS F, Y ", $last_modified);
                $lm = date('l jS \of F Y ', $last_modified);
        	echo 'Last modified : ' . $lm . ' '; ?></div>
</body>
</html>