Torrent not found!';
footer();
die;
}
// extract data from sql
while ($row = mysql_fetch_array($result))
{
extract($row);
stheader('Torrent Details for: '.htmlentities($torrentname));
?>
Description
'.nl2br(str_replace(' ',' ',$descr)).'
';
}
}
else
{
$description = '';
}
echo '';
// Display torrent details
echo '
'.htmlentities($torrentname).'
';
echo '';
echo '';
echo '';
echo '';
//echo '';
//echo '';
echo '';
echo '';
echo '';
echo ''.$description;
echo '';
// Display toggle files link
echo '
';
// Display internal files
echo '
Torrents Internal files
';
echo '';
// Fetch comments from sql
$result = mysql_query("SELECT * FROM comments WHERE id ='".strip_tags(trim($_GET['id']))."'");
$comment_count = mysql_num_rows($result);
// div colors
$color1 = 'class="light"';
$color2 = 'class="dark"';
$row_count = 0;
echo '
Comments ('.$comment_count.')
';
if (!$comment_count == 0)
{
echo '';
}
footer();
}
// Handle posted comment
else
{
$result = mysql_query("SELECT * FROM ban WHERE ip = '$REMOTE_ADDR'");
if (mysql_num_rows($result) == 1)
{
stheader('You have been banned from this section!');
echo '
Banned!
You have been banned from this section of the site for a very very very good reason, if you think a mistake has been made feel free to contact one of the admins';
footer();
die;
}
$commentid = strip_tags(trim($_GET['id']));
$name = trim($_POST['user']);
$comment = trim($_POST['comment']);
$ip= $REMOTE_ADDR;
$date = date('YmdHis');
if ($comment == '' || $name == '')
{
stheader('Comment failed!');
echo '
Please fill out the entire form!
';
footer();
die;
}
stheader('Comment submitted');
mysql_query("INSERT INTO comments (id,ip,date,name,post) VALUES ('$commentid','$ip','$date','$name','$comment')");
echo '';
footer();
}
?>
'.nl2br(htmlentities($post)).'
'; $row_count++; } } $result = mysql_query("SELECT * FROM ban WHERE ip = '$REMOTE_ADDR'"); if (mysql_num_rows($result) == 1) { echo '
You cant add any comments!
You cant add any comments because you where banned for some reason.'; footer(); die; } echo '