rendered paste body<?php
require("/usr/home/public_html/links/resources/LinkSql.inc.php");
$db = new LinkSQL($DBName);
if (empty($page)){
$page = 0;
}
$record = 20;
$PicturePath = "/usr/home/public_html/links/resources/photo/";
if (empty($catid)){
$catid = 0;
}
$cataresult = $db->getchildcatalog($catid);
$linkresult = $db->getlinks($page,$record,$catid);
?>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=<?php print
"$front_charset"; ?>">
<link rel="stylesheet" href="./style/style.css" type="text/css">
<script language="JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
// -->
</script>
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0">
<?php
include("/usr/home/public_html/links/resources/top.php3");
?>
<?php
if (!empty($cataresult)) {
?>
>> <?php print "$front_categories"; ?>
<?php
while ( list($key,$val)=each($cataresult) ) {
$catalogid = stripslashes($val["catalogid"]);
$catalogname = stripslashes($val["catalogname"]);
?>
<a href="<?php print "$PHP_SELF?catid=$catalogid"; ?>"><?php print "$catalogname"; ?></a><br>
<?php
}
?>
<?php
}
if (!empty($linkresult)) {
?>
<?php
while ( list($key,$val)=each($linkresult) ) {
$title = stripslashes($val["title"]);
$url = stripslashes($val["url"]);
$description = stripslashes($val["description"]);
$picture = stripslashes($val["picture"]);
$code = stripslashes($val["code"]);
if (!empty($code)) {
print "$code<br><br>";
}else{
print "<a href=\"$url\" target=\"_blank\">";
if (!empty($picture)){
print "<img src=\"$PicturePath$picture\" alt=\"$title\" border=\"0\">";
}else{
print "$title";
}
print "</a>";
if (!empty($description)) {
print "-- $description";
}
print "<br><br>";
}
}
?>
<?php
$pagenext = $page+1;
$result1 = $db->getlinks($pagenext,$record,$catid);
if ($page!=0)
{
$pagepre = $page-1;
print "<a href=\"$PHP_SELF?page=$pagepre&catid=$catid\"><font color=\"#FF0000\">$front_previouspage</font></a> ";
}
if (!empty($result1))
{
print "<a href=\"$PHP_SELF?page=$pagenext&catid=$catid\"><font color=\"#FF0000\">$front_nextpage</font></a> ";
}
?>
<?php
}
?>
<?php
include("/usr/home/public_html/links/resources/bottom.php3");
?>