View Single Post
  #11  
Old 25th September 2013, 23:16
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 2,113
Default
here is a template for brows page

HTML Code:
<!-- INCLUDE themes/Bitfarm/templates/over_all_header.html -->

<!-- INCLUDE themes/Bitfarm/templates/over_all_left.html -->

<br clear="all" >

<!-- INCLUDEPHP blocks/torrents-needseed.php -->

<br clear="all" >

<!-- INCLUDE themes/Bitfarm/templates/search_block.html -->

<br clear="all" >

<!-- IF S_TORRENTS -->

<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onclick="toggle2('nnTorrents');">Torrents</a>

</div>

</div>

</div>

</td></tr>

<tr valign="middle">

<td class="row3"><div id="nnTorrents">

<table class="ttable_headinner" border="0" cellpadding="0" cellspacing="0" width="100%">

<tbody><tr>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=4&amp;type=<!-- IF T_SORT == d -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Type desc">Type</a></td>

<td class="ttable_head" align="left"><a href="/torrents.php?sort=1&amp;type=<!-- IF T_SORT == a -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Name asc">Name</a></td>

<td class="ttable_head" align="left">DL</td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=2&amp;type=<!-- IF T_SORT == b -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Number of files desc"><img src="themes/Bitfarm/pics/completed.gif" alt="Number of Files" title="Number of Files" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/comments.png" alt="Comments" title="Comments" border="0"></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/report.gif" alt="Ratings" title="Ratings" border="0"></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=5&amp;type=<!-- IF T_SORT == e -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Number of files desc"><img src="themes/Bitfarm/pics/servers.png" alt="Size" title="Size" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/completed.png" alt="Downloaded" title="Downloaded" border="0"></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=7&amp;type=<!-- IF T_SORT == g -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Seeds desc"><img src="themes/Bitfarm/pics/seeders.png" alt="Seeds" title="Seeds" border="0"></a></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=8&amp;type=<!-- IF T_SORT == h -->{T_SHORT}<!-- ELSE -->desc<!-- ENDIF -->" title="Sort by Leechers desc"><img src="themes/Bitfarm/pics/leechers.png" alt="Leechers" title="Leechers" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/peers.gif" alt="addedby" title="addedby" border="0"></td>

</tr>

<!-- BEGIN torrent_var -->

<tr class="t-row">

<td class="ttable_col1" align="center"><br><a href="/torrents.php?cat={torrent_var.CAT_ID}">{torrent_var.CATEGORY}</a></td>

<td class="ttable_col2" nowrap="nowrap" align="left">

  <nobr>

    <p class="title">

       <nobr>

      <!-- IF torrent_var.NUKED --><img src="themes/Bitfarm/pics/nuked.gif" alt="NUKED TORRENT" title="NUKED TORRENT" border="0"><!-- ENDIF -->

      <!-- IF torrent_var.FREE_DL --><img src="themes/Bitfarm/pics/magic.gif" alt="FREE TORRENT" title="FREE TORRENT" border="0"><!-- ENDIF -->

      <!-- IF torrent_var.DHT_INABLED --><span class="overlib" onmouseover="return overlib('This torrent supports DHT. With a state-of-the-art client, you\'ll be able to download this torrent even if a central tracker goes down.',CAPTION, 'DHT Support',TEXTFONT,'Verdana',TEXTCOLOR,'#FFFFFF',CAPTIONFONT,'Lucida Console, Verdana',LEFT,FGCOLOR,'#000000',BGCOLOR,'#6F7578',CAPICON,'themes/Bitfarm/pics/help.gif',BORDER,2,SHADOW,SHADOWOPACITY,40,SHADOWCOLOR,'#030303',SHADOWX,2,SHADOWY,2);" onmouseout="return nd();" style="cursor: help;">

      <img src="themes/Bitfarm/pics/dht.gif" alt="" title="" border="0"></span><!-- ENDIF -->

      <br />

      <b><a style="text-decoration: none;" href="details.php?id={torrent_var.ID}<!-- IF HIT_COUNT -->&amp;hit=1<!-- ENDIF -->" title="{torrent_var.FULL_NAME}">{torrent_var.SHORTNAME}</a></b>

      </nobr></p><i><u>Added: {torrent_var.DATE_ADDED}</u></i>

      </nobr><br>

      <!-- IF torrent_var.BANNED --><img src="themes/Bitfarm/pics/banned.png" alt="Banned torrent" title="Banned torrent" border="0"><!-- ENDIF -->

      <!-- IF torrent_var.CAN_EDIT --><a href="edit.php?id={torrent_var.ID}"><img src="themes/Bitfarm/pics/edit.gif" alt="Edit" title="Edit" border="0"></a><!-- ENDIF -->

      <!-- IF torrent_var.CAN_DEL --><a href="edit.php?op=delete&amp;id={torrent_var.ID}"><img src="themes/Bitfarm/pics/drop.gif" alt="Delete" title="Delete" border="0"></a><!-- ENDIF -->

      <!-- IF torrent_var.CAN_BAN --><a href="edit.php?op=ban&amp;id={torrent_var.ID}"><img src="themes/Bitfarm/pics/ban.png" alt="Ban Torrent" title="Ban Torrent" border="0"></a><!-- ENDIF -->

      <!-- IF not torrent_var.LOCAL_T --><!-- IF torrent_var.REFRESH_T --><a href="scrape-external.php?id={torrent_var.ID}&amp;tracker={torrent_var.TRACKER_URL}&amp;return=torrents.php"><img src="themes/Bitfarm/pics/refresh.png" alt="Refresh Peer Data" title="Refresh Peer Data" border="0"></a>

      <!-- ELSE --><img src="themes/Bitfarm/pics/refresh_gray.png" alt="Stats Updated less than 30min ago" title="Stats Updated less than 30min ago" border="0"><!-- ENDIF --><!-- ENDIF -->

      <!-- IF torrent_var.NEED_AUTH -->{torrent_var.AUTH_LINK}<!-- ENDIF -->

     

</td>

<td class="ttable_col1" align="center"><br><!-- IF torrent_var.CAN_DOWN_LOAD --><a class="index" href="download.php?id={torrent_var.ID}"><img style="border: medium none ;" alt="download" src="themes/Bitfarm/pics/download2.gif" align="center"></a><!-- ENDIF --></td>

<td class="ttable_col2" align="center"><br><a href="/torrents.php?sort=2&amp;type=desc" title="Sort by Number of files desc">{torrent_var.NUM_FILE}</a></td>

<td class="ttable_col1" align="center"><br><b><a href="details.php?id={torrent_var.ID}&amp;hit={torrent_var.ID}&amp;comm=startcomments">{torrent_var.NUM_COMENTS}</a></b></td>

<td class="ttable_col2" align="center"><br>{torrent_var.RATEING_PIC}</td>

<td class="ttable_col1" align="center"><br>{torrent_var.DOWNLOAD_SIZE}</td>



<td class="ttable_col2" align="center"><br>{torrent_var.TIMES_SNATHED}<br>{L_TIMES}</td>

<td class="ttable_col1" align="center"><b><br>{torrent_var.SEEDERS}</b></td>

<td class="ttable_col2" align="center"><b><br>{torrent_var.LEECHERS}</b></td>

<td class="ttable_col1" align="center"><br><!-- IF torrent_var.ANONUMUS_UPLO -->{L_ANONUMUS} <!-- ELSE --> <a href="user.php?op=profile&amp;id={torrent_var.UPLODER_ID}"><font color="{torrent_var.UPLDER_COLOR}">{torrent_var.UPLOADERS_NAM}</font></a><!-- ENDIF --></td>

</tr>

<!-- END torrent_var -->

      </tr>

    </tbody>

  </table>

</div>

<br clear="all" >

<br clear="all">

  <div class="pagination">

    <span>

      <strong>Pages {CURENT_PAGE}/{TOTTAL_PAGES}</strong>

    </span><span>

      <!-- IF not PREV_PAGE --><strong>&lt;&lt;&lt;&lt;</strong><!-- ELSE --><a href="torrents.php?page={PREV_PAGE}">&lt;&lt;&lt;&lt;</a><!-- ENDIF -->

{GENERATED_PAGES}

        <!-- IF not NEXT_PAGE --><strong>&gt;&gt;&gt;&gt;</strong><!-- ELSE --><a href="torrents.php?page={NEXT_PAGE}">&gt;&gt;&gt;&gt;</a><!-- ENDIF -->

        <span>

        </span>

      </span>

    </span>

  </span>

</div><tr>

<td colspan="7" valign="middle" align="center"></td>

</tr>

</td></table>

<br clear="all" >

<br clear="all">

<!-- ELSE -->

<table class="tablebg" width="100%" cellspacing="0">

<tbody><tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">



<a class="c4" style="cursor: pointer; float: left;" onclick="toggle2('nn ');"><img title="Expand item" id="nn&nbsp;img" src="themes/Bitfarm/pics/minus.gif" alt="+"></a>&nbsp;

</div>

</div>

</div>

</td></tr><tr valign="middle">

<td class="row3">

<div id="nn&nbsp;">

<h3>{L_NO_TORRENTS}</h3>

</div>

</td></tr>

<tr>



<td colspan="7" valign="middle" align="center"></td>

</tr>

</tbody></table>

<br clear="all">

<!-- ENDIF -->

<!-- INCLUDEPHP blocks/searchcloud.php -->

<!-- INCLUDE themes/Bitfarm/templates/over_all_right.html -->

<!-- INCLUDE themes/Bitfarm/templates/over_all_footer.html -->
as you can see NO php in my templates!
It takes close to 200 templates to create a theme for my source code and you can make your site look how ever you want it to.
BTManager ONLY creates the info no the layout that is left to the theme and to speed things up I cache the processed template

this is Bitfarm_torrents_body.html.php

PHP Code:
<?php if (!defined('IN_PMBT')) die('cheat'); ?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><!-- testing -->
<head>
<meta name="generator" content="HTML Tidy for Linux (vers 6 November 2007), see www.w3.org">
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo (isset($this->_rootref['S_CONTENT_ENCODING'])) ? $this->_rootref['S_CONTENT_ENCODING'] : ''?>">
<meta name="generator" content="PMBT <?php echo (isset($this->_rootref['PMBT_VER'])) ? $this->_rootref['PMBT_VER'] : ''?>">
<meta http-equiv="PRAGMA" content="NO-CACHE">
<meta http-equiv="EXPIRES" content="-1">
<meta http-equiv="Cache-Control" content="no-cache">
<link rel="shortcut icon" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/favicon.ico" type="image/x-icon" >
<link rel="search" type="application/opensearchdescription+xml" title="<?php echo (isset($this->_rootref['SITENAME'])) ? $this->_rootref['SITENAME'] : ''?>" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/opensearch.php">
<link rel="alternate" type="application/rss+xml" title="Last Torrents" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/backend.php?op=last">
<link rel="alternate" type="application/rss+xml" title="Best Torrents" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/backend.php?op=best">
<link rel="StyleSheet" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/style.css" type="text/css">
<link rel="stylesheet" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/css/lightbox.css" type="text/css">
<?php echo (isset($this->_rootref['META'])) ? $this->_rootref['META'] : ''?>
<!--[if lt IE 7]>
<script defer type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/pngfix.js"></script>
<![endif]-->
<title><?php echo (isset($this->_rootref['SITENAME'])) ? $this->_rootref['SITENAME'] : ''?> &bull; <?php if ($this->_rootref['S_IN_MCP']) {  echo ((isset($this->_rootref['L_MCP'])) ? $this->_rootref['L_MCP'] : ((isset($user->lang['MCP'])) ? $user->lang['MCP'] : ((defined('MCP')) ? MCP '{ MCP }'))); ?> &bull; <?php } else if ($this->_rootref['S_IN_UCP']) {  echo ((isset($this->_rootref['L_USER_CPANNEL'])) ? $this->_rootref['L_USER_CPANNEL'] : ((isset($user->lang['USER_CPANNEL'])) ? $user->lang['USER_CPANNEL'] : ((defined('USER_CPANNEL')) ? USER_CPANNEL '{ USER_CPANNEL }'))); ?> &bull; <?php } echo (isset($this->_rootref['PAGE_TITLE'])) ? $this->_rootref['PAGE_TITLE'] : ''?></title>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/prototype.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/scriptaculous.js?load=effects,builder"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/lightbox.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.smoothmenu.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/core.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/ncode_imageresizer.js"></script>
<script type="text/javascript">
<!--
NcodeImageResizer.MODE = 'newwindow';
NcodeImageResizer.MAXWIDTH = 500;
NcodeImageResizer.MAXHEIGHT =400;

NcodeImageResizer.Msg1 = 'Click here to view the full image.';
NcodeImageResizer.Msg2 = 'This image has been resized. Click image to view the full image.';
NcodeImageResizer.Msg3 = 'This image has been resized. Click image to view the full image.';
NcodeImageResizer.Msg4 = 'Click here to view the small image.';
//-->
</script>
<script type="text/javascript">
pmbtsite_url = "<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>";
tag_prompt = "Enter a Text:";
img_prompt = "Insert Link from Image";
font_formatter_prompt = "Enter a Text - ";
link_text_prompt = "Enter a Link Name (Optional):";
link_url_prompt = "Enter the Full Address on the left of:";
link_email_prompt = "Enter your Full Link:";
list_type_prompt = "Which type of List would you like? Give ' 1 ' for a Numerical List, 'a' for an Alphabetical List, or nothing at all for a Simple Point List.";
list_item_prompt = "Enter one point of list. Press OK to enter another point of list or press 'Cancel' to Finish.";
_btshoutnowprivate = "<?php echo ((isset($this->_rootref['L_PRIVATE_SHOUT'])) ? $this->_rootref['L_PRIVATE_SHOUT'] : ((isset($user->lang['PRIVATE_SHOUT'])) ? $user->lang['PRIVATE_SHOUT'] : ((defined('PRIVATE_SHOUT')) ? PRIVATE_SHOUT '{ PRIVATE_SHOUT }'))); ?>";
shoutrefresht = "<?php echo (isset($this->_rootref['S_SHOUT_REF'])) ? $this->_rootref['S_SHOUT_REF'] : ''?>";
shoutidle = "<?php echo (isset($this->_rootref['S_SHOUT_IDL'])) ? $this->_rootref['S_SHOUT_IDL'] : ''?>";
function change_bg(img, state)
{
if (state == "1") 
img.src = img.src.replace(".gif","_over.gif");
else if (state == "0") 
img.src = img.src.replace("_over.gif",".gif");
else if (state == "2") 
img.src = img.src.replace("_over.gif",".gif");
else if (state == "3") 
img.src = img.src.replace("_over.gif",".gif");
}
var pd = new Date();
var last_reload = pd.getTime();
function do_breload() {
    if (document.location.href.match(/\/torrents\.php/)) {
       var d = new Date();
       if (last_reload && last_reload > (d.getTime() - "4000")) return;
          last_reload = d.getTime();   
       bparam('page=1')       

    }
}

function toggle2(nome) {
if(document.getElementById(nome).style.display=='none')
{
SetCookie(nome,'');
document.getElementById(nome).style.display = '';
document.getElementById(nome+"img").src="themes/Bitfarm/pics/minus.gif";
} else {
SetCookie(nome,'none',200);
document.getElementById(nome).style.display = 'none';
document.getElementById(nome+"img").src="themes/Bitfarm/pics/plus.gif";
}
}

function SetCookie(cookieName,cookieValue,nDays) {
 var today = new Date();
 var expire = new Date();
 if (nDays==null || nDays==0) nDays=1;
 expire.setTime(today.getTime() + 3600000*24*nDays);
 document.cookie = cookieName+"="+escape(cookieValue)
                 + ";expires="+expire.toGMTString();
}
function bparam(){
    document.getElementById('myAnchor').href="torrents.php"
}
// <![CDATA[
var jump_page = '<?php echo ((isset($this->_rootref['LA_JUMP_PAGE'])) ? $this->_rootref['LA_JUMP_PAGE'] : ((isset($this->_rootref['L_JUMP_PAGE'])) ? addslashes($this->_rootref['L_JUMP_PAGE']) : ((isset($user->lang['JUMP_PAGE'])) ? addslashes($user->lang['JUMP_PAGE']) : '{ JUMP_PAGE }'))); ?>:';
var on_page = '<?php echo (isset($this->_rootref['ON_PAGE'])) ? $this->_rootref['ON_PAGE'] : ''?>';
var per_page = '<?php echo (isset($this->_rootref['PER_PAGE'])) ? $this->_rootref['PER_PAGE'] : ''?>';
var base_url = '<?php echo (isset($this->_rootref['A_BASE_URL'])) ? $this->_rootref['A_BASE_URL'] : ''?>';

var menu_state = 'shown';


/**
* Jump to page
*/
function jumpto()
{
    var page = prompt(jump_page, on_page);

    if (page !== null && !isNaN(page) && page == Math.floor(page) && page > 0)
    {
        if (base_url.indexOf('?') == -1)
        {
            document.location.href = base_url + '?page=' + ((page - 1) * per_page/per_page+1);
        }
        else
        {
            document.location.href = base_url.replace(/&amp;/g, '&') + '&page=' + ((page - 1) * per_page/per_page+1);
        }
    }
}

/**
* Set display of page element
* s[-1,0,1] = hide,toggle display,show
*/
function dE(n, s, type)
{
    if (!type)
    {
        type = 'block';
    }

    var e = document.getElementById(n);
    if (!s)
    {
        s = (e.style.display == '') ? -1 : 1;
    }
    e.style.display = (s == 1) ? type : 'none';
}
// ]]>
</script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/global.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/overlib/overlib.js"><!-- overLIB (c) Erik Bosrup --></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/overlib/overlib_shadow.js"><!-- overLIB (c) Erik Bosrup --></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.js" type="text/javascript"></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery-ui-1.7.2.custom.min.js" type="text/javascript"></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/ui.selectmenu.js" type="text/javascript"></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.cookie.js" type="text/javascript"></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.thumbnailScroller.js" type="text/javascript"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.smoothmenu.js"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/core.js"></script>    
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.jcarousel.js" type="text/javascript"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.qtip-1.0.0-rc3.min.js"></script>
<script src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/init.js" type="text/javascript"></script>
<script type="text/javascript" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/js/jquery.jqDock.min.js"></script>
<script type="text/javascript">
    $(function(){
        var jqDockOpts = {align: 'left', duration: 200, labels: 'tc', size: 48, distance: 85};
        $('#jqDock').jqDock(jqDockOpts);
    });
</script>
</head>
<!--[if lt IE 7]><link rel="stylesheet" type="text/css" media="screen" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/iestyle.css">
<![endif]-->
<!--[if IE]>
<link rel="stylesheet" type="text/css" media="screen" href="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/iestyle.css">
<![endif]-->
<body class="ltr" onLoad="shoutthis_ajax()">
<div id="overDiv" style="position:absolute; visibility:hidden; z-index:1000;"></div>
<div align="center">
<div id="infobar">
<div class="fltLeft"><?php if ($this->_rootref['U_ADMIN']) {  ?><a class='admin' href='admin.php'><?php echo ((isset($this->_rootref['L_ADMIN_CP'])) ? $this->_rootref['L_ADMIN_CP'] : ((isset($user->lang['ADMIN_CP'])) ? $user->lang['ADMIN_CP'] : ((defined('ADMIN_CP')) ? ADMIN_CP '{ ADMIN_CP }'))); ?></a><?php ?></div>
<div class="fltRight">
You are logged in as: <a href="user.php?op=profile"><font color="#000" style='background-color: <?php echo (isset($this->_rootref['U_USER_COLOR'])) ? $this->_rootref['U_USER_COLOR'] : ''?>;'><?php echo (isset($this->_rootref['U_USER_USERNAME'])) ? $this->_rootref['U_USER_USERNAME'] : ''?></font></a>,
<img width="20" height="20" border="none" title="Uploaded" alt="Uploaded" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/uploaded.png">
<font color="#009900"><?php echo (isset($this->_rootref['U_UPLOADED'])) ? $this->_rootref['U_UPLOADED'] : ''?> </font>
<img width="20" height="20" border="none" title="Downloaded" alt="Downloaded" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/downloaded.png">
<font color="#CC0000"><?php echo (isset($this->_rootref['U_DOWNLOADED'])) ? $this->_rootref['U_DOWNLOADED'] : ''?> </font>
<img width="20" height="20" border="none" title="Ratio" alt="Ratio" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/ratio.png">
<?php echo (isset($this->_rootref['U_RATIO'])) ? $this->_rootref['U_RATIO'] : ''?>
<a href="user.php?op=editprofile">
<img width="20" height="20" border="none" title="Your account" alt="Your account" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/account.png">
</a>
<a href="user.php?op=profile">
<img width="20" height="20" border="none" title="Profile" alt="Profile" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/profile.png">
</a>
<a onClick="if(!confirm('Are you sure do you want to logout?')){return false;};" href="user.php?op=logout" alt="logout" title="Logout">
<img width="20" height="20" border="none" title="Logout" alt="Logout" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/logout.png">
</a>
<a href="pm.php">
<img width="20" height="20" border="none" s'="" title="PM" alt="PM" src="<?php echo (isset($this->_rootref['SITE_URL'])) ? $this->_rootref['SITE_URL'] : ''?>/themes/Bitfarm/images/<?php if ($this->_rootref['U_USER_NEW_PM']) {  ?>mail_new.png<?php } else { ?>mail.png<?php ?>">
</a>
</div>
</div>
</div>
<div id="h_w">
<td align="center">
<div id="letter-container" class="letter-container">
<h4>
<a href="#">
<span class="char1">B</span>
<span class="char2">T</span>
<span class="char3">M</span>
<span class="char4">A</span>
<span class="char5">N</span>
<span class="char6">A</span>
<span class="char7">G</span>
<span class="char8">E</span>
<span class="char9">R</span>
</a>
</h4>
</div>
</td>
</tr>
</div>
<div id="c_w">
<div id="nav-holder">
<div id="nav">
<ul>
<li><a title="Home" href="/"><?php echo ((isset($this->_rootref['L_INDEX'])) ? $this->_rootref['L_INDEX'] : ((isset($user->lang['INDEX'])) ? $user->lang['INDEX'] : ((defined('INDEX')) ? INDEX '{ INDEX }'))); ?></a>
</li>
<li>
<a title="Home" href="/torrents.php"><?php echo ((isset($this->_rootref['L_BROWES'])) ? $this->_rootref['L_BROWES'] : ((isset($user->lang['BROWES'])) ? $user->lang['BROWES'] : ((defined('BROWES')) ? BROWES '{ BROWES }'))); ?></a>
</li>
<li>
<a title="Home" href="/upload.php"><?php echo ((isset($this->_rootref['L_UPLOAD'])) ? $this->_rootref['L_UPLOAD'] : ((isset($user->lang['UPLOAD'])) ? $user->lang['UPLOAD'] : ((defined('UPLOAD')) ? UPLOAD '{ UPLOAD }'))); ?></a>
</li>
<?php if ($this->_rootref['U_USER']) {  ?><li class="dropdown">
<a id="hoverdown" href="#"><?php echo ((isset($this->_rootref['L_USER'])) ? $this->_rootref['L_USER'] : ((isset($user->lang['USER'])) ? $user->lang['USER'] : ((defined('USER')) ? USER '{ USER }'))); ?>
<img width="8" height="10" border="0" title="DEVICE's" alt="DEVICE'S" src="themes/Bitfarm/images/dropdown-arrow.png" style="margin-left:10px">
</a>
<ul class="sub_nav" style="display: none;">
<li>
<a alt="profioe" href="/user.php?op=profile"><?php echo ((isset($this->_rootref['L_USERPROFILE'])) ? $this->_rootref['L_USERPROFILE'] : ((isset($user->lang['USERPROFILE'])) ? $user->lang['USERPROFILE'] : ((defined('USERPROFILE')) ? USERPROFILE '{ USERPROFILE }'))); ?></a>
</li>
<li>
<a alt="edit" href="/user.php?op=editprofile"><?php echo ((isset($this->_rootref['L_USEREPROFILE'])) ? $this->_rootref['L_USEREPROFILE'] : ((isset($user->lang['USEREPROFILE'])) ? $user->lang['USEREPROFILE'] : ((defined('USEREPROFILE')) ? USEREPROFILE '{ USEREPROFILE }'))); ?></a>
</li>
<li>
<a alt="board" href="/user.php?op=editprofile&id=1&action=preferences&mode=personal">Board Settings</a>
</li>
<li>
<a alt="subs" href="/user.php?op=editprofile&id=?&action=overview&mode=subscribed">Subscriptions</a>
</li>
</ul>
</li><?php ?>
<li>
<a title="forums" href="/forum.php"><?php echo ((isset($this->_rootref['L_FORUM'])) ? $this->_rootref['L_FORUM'] : ((isset($user->lang['FORUM'])) ? $user->lang['FORUM'] : ((defined('FORUM')) ? FORUM '{ FORUM }'))); ?></a>
</li>
<li>
<a title="support" href="http://btmanager.com">Support</a>
</li>
</ul>
</div>
</div>


<table width="100%" cellspacing="10" cellpadding="0" border="0">
<tbody>
<tr>
<td width="15%" valign="top">
<?php if ($this->_rootref['U_USER']) {  ?>

<table class="tablebg" width="100%" cellspacing="0">
<tr>
<td>
<div class="caption">
<div class="cap-left">
<div class="cap-right">
<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnPersonal_stats');">Personal stats</a>
</div>
</div>
</div>
</td></tr><tr valign="middle">

<td  class="row3" ><div id="nnPersonal_stats">

<p align="center"><b>Welcome Back</b></p>

<p align="center"><b><?php echo (isset($this->_rootref['U_USER_USERNAME'])) ? $this->_rootref['U_USER_USERNAME'] : ''?></b></p>

<center><b><?php echo (isset($this->_rootref['U_AVATAR'])) ? $this->_rootref['U_AVATAR'] : ''?></b><br><br></center>

<p><img src="themes/Bitfarm/pics/pic_uploaded.gif" border="0" alt="" title=""   /><?php echo (isset($this->_rootref['U_UPLOADED'])) ? $this->_rootref['U_UPLOADED'] : ''?><br><img src="themes/Bitfarm/pics/pic_downloaded.gif" border="0" alt="" title=""   /><?php echo (isset($this->_rootref['U_DOWNLOADED'])) ? $this->_rootref['U_DOWNLOADED'] : ''?><br><img src="themes/Bitfarm/pics/pic_ratio.gif" border="0" alt="" title=""   />&nbsp;<?php echo (isset($this->_rootref['U_RATIO'])) ? $this->_rootref['U_RATIO'] : ''?><br>

<?php if ($this->_rootref['U_TSEEDING']) {  ?><span class="overlib" onMouseOver="return overlib('<?php echo (isset($this->_rootref['U_TSEEDING'])) ? $this->_rootref['U_TSEEDING'] : ''?>',CAPTION, 'Torrents you are Seeding',TEXTFONT,'Verdana',TEXTCOLOR,'#FFFFFF',CAPTIONFONT,'Lucida Console, Verdana',CENTER,FGCOLOR,'#000000',BGCOLOR,'#6F7578',CAPICON,'themes/Bitfarm/pics/help.png',BORDER,2,SHADOW,SHADOWOPACITY,40,SHADOWCOLOR,'#030303',SHADOWX,2,SHADOWY,2);" onMouseOut="return nd();" style="cursor:help"><?php ?>

<img src="themes/Bitfarm/pics/upload.gif" border="0" alt="" title=""   /></span><?php echo (isset($this->_rootref['U_TSEEDING_CNT'])) ? $this->_rootref['U_TSEEDING_CNT'] : ''?><br>

<?php if ($this->_rootref['U_TLEECHING']) {  ?><span class="overlib" onmouseover="return overlib('<?php echo (isset($this->_rootref['U_TLEECHING'])) ? $this->_rootref['U_TLEECHING'] : ''?>',CAPTION, 'Torrents you are Seeding',TEXTFONT,'Verdana',TEXTCOLOR,'#FFFFFF',CAPTIONFONT,'Lucida Console, Verdana',CENTER,FGCOLOR,'#000000',BGCOLOR,'#6F7578',CAPICON,'themes/Bitfarm/pics/help.png',BORDER,2,SHADOW,SHADOWOPACITY,40,SHADOWCOLOR,'#030303',SHADOWX,2,SHADOWY,2);" onmouseout="return nd();" style="cursor:help"><?php ?>

<img src="themes/Bitfarm/pics/download.gif" border="0" alt="Torrents you are Downloading" title="Torrents you are Downloading"   /><?php echo (isset($this->_rootref['U_TLEECHINGCNT'])) ? $this->_rootref['U_TLEECHINGCNT'] : ''?></p><br>

<br>

<p>Seeding Bonus: <a href='mybonus.php'><?php echo (isset($this->_rootref['U_SEED_BONUS'])) ? $this->_rootref['U_SEED_BONUS'] : ''?></a></p>

<p>Transfer Bonus: <a href="bonus_transfer.php">here</a></p>

</div>

</td></tr>

</table>

<br clear="all" >



<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnGeneral');"><?php echo ((isset($this->_rootref['L_GENERAL'])) ? $this->_rootref['L_GENERAL'] : ((isset($user->lang['GENERAL'])) ? $user->lang['GENERAL'] : ((defined('GENERAL')) ? GENERAL '{ GENERAL }'))); ?></a>

</div>

</div>

</div>

</td></tr><tr valign="middle">

<td  class="row3" ><div id="nnGeneral">

<table width="100%" border="0" cellspacing="1" cellpadding="1" class="forumline" align="center">

<tr><td class="row2" width="100%"><a href="index.php"><?php echo ((isset($this->_rootref['L_INDEX'])) ? $this->_rootref['L_INDEX'] : ((isset($user->lang['INDEX'])) ? $user->lang['INDEX'] : ((defined('INDEX')) ? INDEX '{ INDEX }'))); ?> </a></td></tr>

<tr><td class="row1" width="100%"><a href="rules.php"><?php echo ((isset($this->_rootref['L_RULES'])) ? $this->_rootref['L_RULES'] : ((isset($user->lang['RULES'])) ? $user->lang['RULES'] : ((defined('RULES')) ? RULES '{ RULES }'))); ?></a></td></tr>

<tr><td class="row2" width="100%"><a href="faq.php"><?php echo ((isset($this->_rootref['L_FAQS'])) ? $this->_rootref['L_FAQS'] : ((isset($user->lang['FAQS'])) ? $user->lang['FAQS'] : ((defined('FAQS')) ? FAQS '{ FAQS }'))); ?></a></td></tr>



<tr><td class="row1" width="100%"><a href="forum.php"><?php echo ((isset($this->_rootref['L_FORUM'])) ? $this->_rootref['L_FORUM'] : ((isset($user->lang['FORUM'])) ? $user->lang['FORUM'] : ((defined('FORUM')) ? FORUM '{ FORUM }'))); ?></a></td></tr>

<tr><td class="row1" width="100%"><a href="chat.php"><?php echo ((isset($this->_rootref['L_IRC_CHAT'])) ? $this->_rootref['L_IRC_CHAT'] : ((isset($user->lang['IRC_CHAT'])) ? $user->lang['IRC_CHAT'] : ((defined('IRC_CHAT')) ? IRC_CHAT '{ IRC_CHAT }'))); ?></a></td></tr>

<?php if ($this->_rootref['U_USER']) {  ?><tr><td class="row1" width="100%"><a href="mytorrents.php"><?php echo ((isset($this->_rootref['L_YOUR_TORRENTS'])) ? $this->_rootref['L_YOUR_TORRENTS'] : ((isset($user->lang['YOUR_TORRENTS'])) ? $user->lang['YOUR_TORRENTS'] : ((defined('YOUR_TORRENTS')) ? YOUR_TORRENTS '{ YOUR_TORRENTS }'))); ?></a></td></tr><?php ?>

<tr><td class="row1" width="100%"><a href="torrents.php"><?php echo ((isset($this->_rootref['L_BROWES'])) ? $this->_rootref['L_BROWES'] : ((isset($user->lang['BROWES'])) ? $user->lang['BROWES'] : ((defined('BROWES')) ? BROWES '{ BROWES }'))); ?></a></td></tr>

<?php if ($this->_rootref['U_USER']) {  ?><tr><td class="row1" width="100%"><a href="pm.php"><span id="nopm_notif"><?php echo ((isset($this->_rootref['L_PRIVATE_MESSAGES'])) ? $this->_rootref['L_PRIVATE_MESSAGES'] : ((isset($user->lang['PRIVATE_MESSAGES'])) ? $user->lang['PRIVATE_MESSAGES'] : ((defined('PRIVATE_MESSAGES')) ? PRIVATE_MESSAGES '{ PRIVATE_MESSAGES }'))); ?></span></a></td></tr><?php } if ($this->_rootref['U_USER']) {  ?><tr><td class="row1" width="100%"><a href="user.php?op=profile&amp;id=<?php echo (isset($this->_rootref['S_USER_ID'])) ? $this->_rootref['S_USER_ID'] : ''?>"><?php echo ((isset($this->_rootref['L_USER_CPANNEL'])) ? $this->_rootref['L_USER_CPANNEL'] : ((isset($user->lang['USER_CPANNEL'])) ? $user->lang['USER_CPANNEL'] : ((defined('USER_CPANNEL')) ? USER_CPANNEL '{ USER_CPANNEL }'))); ?></a></td></tr><?php } if ($this->_rootref['U_USER']) {  ?><tr><td class="row1" width="100%"><a onClick="if(!confirm('Are you sure do you want to logout?')){return false;};" href="user.php?op=logout" alt="logout"  title="Logout"><?php echo ((isset($this->_rootref['L_LOG_OUT'])) ? $this->_rootref['L_LOG_OUT'] : ((isset($user->lang['LOG_OUT'])) ? $user->lang['LOG_OUT'] : ((defined('LOG_OUT')) ? LOG_OUT '{ LOG_OUT }'))); ?></a></td></tr><?php } if ($this->_rootref['U_ADMIN']) {  ?><tr><td class="row1" width="100%"><a href="admin.php"><?php echo ((isset($this->_rootref['L_ADMIN_CP'])) ? $this->_rootref['L_ADMIN_CP'] : ((isset($user->lang['ADMIN_CP'])) ? $user->lang['ADMIN_CP'] : ((defined('ADMIN_CP')) ? ADMIN_CP '{ ADMIN_CP }'))); ?></a></td></tr><?php ?>

</table>

</div>

</td></tr>

</table>

<br clear="all" >



<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnTheme_change');">Theme change</a>

</div>

</div>

</div>

</td></tr><tr valign="middle">

<td  class="row3" ><div id="nnTheme_change">

<p align="center"><b><?php echo ((isset($this->_rootref['L_THEMES'])) ? $this->_rootref['L_THEMES'] : ((isset($user->lang['THEMES'])) ? $user->lang['THEMES'] : ((defined('THEMES')) ? THEMES '{ THEMES }'))); ?></b></p>

<form id="acp_styles" type="hidden" method="post" action="#"><p><select id="template_file" name="theme_change" onChange="if (this.options[this.selectedIndex].value != '') this.form.submit();">

<?php $_theme_var_count = (isset($this->_tpldata['theme_var'])) ? sizeof($this->_tpldata['theme_var']) : 0;if ($_theme_var_count) {for ($_theme_var_i 0$_theme_var_i $_theme_var_count; ++$_theme_var_i){$_theme_var_val = &$this->_tpldata['theme_var'][$_theme_var_i]; ?>

<option <?php if ($_theme_var_val['SET']) {  ?>selected="selected" <?php ?> value="<?php echo $_theme_var_val['KEY']; ?>"><?php echo $_theme_var_val['VAL']; ?></option>

<?php }} ?>

</select></p><p align="center"><b><?php echo ((isset($this->_rootref['L_LANGUAGE'])) ? $this->_rootref['L_LANGUAGE'] : ((isset($user->lang['LANGUAGE'])) ? $user->lang['LANGUAGE'] : ((defined('LANGUAGE')) ? LANGUAGE '{ LANGUAGE }'))); ?></b></p>

<p><select id="language_file" name="language_change" onChange="if (this.options[this.selectedIndex].value != '') this.form.submit();">

<?php $_lang_var_count = (isset($this->_tpldata['lang_var'])) ? sizeof($this->_tpldata['lang_var']) : 0;if ($_lang_var_count) {for ($_lang_var_i 0$_lang_var_i $_lang_var_count; ++$_lang_var_i){$_lang_var_val = &$this->_tpldata['lang_var'][$_lang_var_i]; ?>

<option  <?php if ('lang_varS.SET') {  ?>selected="selected" <?php ?>value="<?php echo $_lang_var_val['KEY']; ?>"><?php echo $_lang_var_val['VAL']; ?></option>

<?php }} ?>

</select></p> <input class="button2" type="submit" value="SELECT" ></form></div>

</td></tr>

</table>

<br clear="all" >

<?php if ($this->_rootref['DONATIO_ON']) {  ?>

<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnDonations');"><?php echo ((isset($this->_rootref['L_DONATIONS'])) ? $this->_rootref['L_DONATIONS'] : ((isset($user->lang['DONATIONS'])) ? $user->lang['DONATIONS'] : ((defined('DONATIONS')) ? DONATIONS '{ DONATIONS }'))); ?></a>

</div>

</div>

</div>

</td></tr>

<tr valign="middle">

<td  class="row3" ><div id="nnDonations">

<p class="donation" align="center" ><br><?php echo ((isset($this->_rootref['L_PROGRESS'])) ? $this->_rootref['L_PROGRESS'] : ((isset($user->lang['PROGRESS'])) ? $user->lang['PROGRESS'] : ((defined('PROGRESS')) ? PROGRESS '{ PROGRESS }'))); ?></p>



<table class=main border=0 width=144px>

<tr>



<td style='padding: 0px; background-image: url(images/loadbarbg.gif); background-repeat: repeat-x'><?php echo (isset($this->_rootref['DONATION_IMAGE'])) ? $this->_rootref['DONATION_IMAGE'] : ''?>

<br>

<p class="donation" align="center" ><?php echo (isset($this->_rootref['DONATION_PERC'])) ? $this->_rootref['DONATION_PERC'] : ''?>%</p>

</td>

</tr>

</table><p class="donation"> <?php echo ((isset($this->_rootref['L_GOAL'])) ? $this->_rootref['L_GOAL'] : ((isset($user->lang['GOAL'])) ? $user->lang['GOAL'] : ((defined('GOAL')) ? GOAL '{ GOAL }'))); ?> 

<font color="red"><?php echo (isset($this->_rootref['DONATION_ASKED'])) ? $this->_rootref['DONATION_ASKED'] : ''?></font><br>

 <?php echo ((isset($this->_rootref['L_COLECTED'])) ? $this->_rootref['L_COLECTED'] : ((isset($user->lang['COLECTED'])) ? $user->lang['COLECTED'] : ((defined('COLECTED')) ? COLECTED '{ COLECTED }'))); ?> 

 <font color="green"><?php echo (isset($this->_rootref['DONATION_IN'])) ? $this->_rootref['DONATION_IN'] : ''?></font>

 </p>

<br><br>



<B><font color=red>&raquo;</font></B>

<a href="donate.php"><?php echo ((isset($this->_rootref['L_DONATE'])) ? $this->_rootref['L_DONATE'] : ((isset($user->lang['DONATE'])) ? $user->lang['DONATE'] : ((defined('DONATE')) ? DONATE '{ DONATE }'))); ?></a><br></div>

</td></tr>

</table>

<br clear="all" >
<?php ?>


<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnInvites');">Invites</a>

</div>

</div>

</div>

</td></tr><tr valign="middle">

<td  class="row3" ><div id="nnInvites">

<table border="0" width="100%" cellspacing="0" cellpadding="0">

<tr><td align="center"><p>You have <?php echo (isset($this->_rootref['U_INVITES'])) ? $this->_rootref['U_INVITES'] : ''?> Invites</p><br></td></tr>

<tr><td align="center"><a href=invite.php>Send An Invite</a><br></td></tr>

</table>

</div>

</td>

</tr>

</table>

<br clear="all" >

</div>
</td>
<?php ?>

<td width="100%" valign="top">

<div id="centercolumn">

<br clear="all" >

<?php include('blocks/torrents-needseed.php'); ?>

<br clear="all" >

<table class="tablebg" width="100%" cellspacing="0">
    <tbody>
        <tr>
            <td>
                <div class="caption">
                    <div class="cap-left">
                        <div class="cap-right">
                        Search
                        </div>
                    </div>
                </div>
            </td>
        </tr>
        <tr valign="middle">
            <td class="row3">
                <div id="nnSearch">
                    <script type="text/javascript" src="js/browse.js"></script>  
                    <form method="get" action="search.php"><br>
<?php if ('cats_main') {  ?>
                    <div id="cats" style="display: block;">
                    <table>
                      <tbody align="left">
                        <tr>
                        <td></td>
<?php $_cats_main_count = (isset($this->_tpldata['cats_main'])) ? sizeof($this->_tpldata['cats_main']) : 0;if ($_cats_main_count) {for ($_cats_main_i 0$_cats_main_i $_cats_main_count; ++$_cats_main_i){$_cats_main_val = &$this->_tpldata['cats_main'][$_cats_main_i]; ?>
                          <td class="nopad" style="padding-bottom: 2px; padding-left: 7px;">
                          <?php echo $_cats_main_val['IMAGE']; ?>&nbsp;&nbsp;
                          <input id="checkAll<?php echo $_cats_main_val['ID']; ?>" onClick="checkAllFields(1,<?php echo $_cats_main_val['ID']; ?>);" type="checkbox">
                          <a href="javascript: ShowHideMainSubCats(<?php echo $_cats_main_val['TABLETYPE']; ?>,<?php echo (isset($this->_rootref['NCATS_VAR'])) ? $this->_rootref['NCATS_VAR'] : ''?>)"><img src="themes/Bitfarm/pics/plus.gif" id="pic<?php echo $_cats_main_val['TABLETYPE']; ?>" alt="Show/Hide" border="0">&nbsp;<?php echo $_cats_main_val['NAME']; ?></a>&nbsp;</td>
<?php }} ?>
                        </tr>
                      </tbody>
                    </table>
                    </div>
<?php $_cats_main_count = (isset($this->_tpldata['cats_main'])) ? sizeof($this->_tpldata['cats_main']) : 0;if ($_cats_main_count) {for ($_cats_main_i 0$_cats_main_i $_cats_main_count; ++$_cats_main_i){$_cats_main_val = &$this->_tpldata['cats_main'][$_cats_main_i]; ?>
                    <div id="tabletype<?php echo $_cats_main_val['TABLETYPE']; ?>" style="display: none;">
                      <table>
                        <tbody align="left">
                          <tr>
<?php $_sub_count = (isset($_cats_main_val['sub'])) ? sizeof($_cats_main_val['sub']) : 0;if ($_sub_count) {for ($_sub_i 0$_sub_i $_sub_count; ++$_sub_i){$_sub_val = &$_cats_main_val['sub'][$_sub_i]; ?>
                            <td class="subcatlink" style="padding-bottom: 2px; padding-left: 7px; width: 14.2857%;">
                            <?php echo $_sub_val['IMAGE']; ?>&nbsp;&nbsp;
                            <input onClick="checkAllFields(2,<?php echo $_sub_val['PARENT_ID']; ?>);" name="cats<?php echo $_sub_val['PARENT_ID']; ?>[]" value="<?php echo $_sub_val['ID']; ?>" type="checkbox"<?php if ($_sub_val['CHECKED']) {  ?> checked<?php ?>>
                            <br /><?php echo $_sub_val['NAME']; ?>
                            </td>
<?php }} ?>
                            <td rowspan="4">&nbsp;</td>
                          </tr>
                        </tbody>
                      </table>
                    </div>
<?php }} } ?>
                    <table align="center" border="0" cellpadding="1" cellspacing="1">
                        <tbody>
                            <tr>
                                <td>
                                </td>
                                <td>
                                <input id="actb_textbox" name="search" value="<?php echo (isset($this->_rootref['SEARCH_TEXT'])) ? $this->_rootref['SEARCH_TEXT'] : ''?>" size="25" type="text"> 
                                </td>
                                <td>
                                <?php echo (isset($this->_rootref['S_ACTB'])) ? $this->_rootref['S_ACTB'] : ''?>
                                <script type="text/javascript" language="JavaScript">actb(document.getElementById("actb_textbox"),customarray);</script>
                                </td>
                                <td><input value="Go!" type="submit">
                                </td>
                            </tr>
                        </tbody>
                    </table>
                    <table align="center" border="0" cellpadding="1" cellspacing="1">
                        <tbody>
                            <tr>
                                <td><p>Order By:</p></td>
                                <td>
                                <select name="orderby">
                                <option value="0" selected="selected">Date</option>
                                <option value="1">Seeds</option>
                                <option value="2">Leechers</option>
                                <option value="3">Total Peers</option>
                                <option value="4">Downloaded</option>
                                <option value="5">Ratings</option>
                                <option value="6">Name</option>
                                <option value="7">Size</option>
                                <option value="8">Number of Files</option>
                                </select>
                                </td>
                                <td>
                                <select name="ordertype"><option value="DESC">Descending</option><option value="ASC">Ascending</option></select>
                                </td>
                                <td>
                                <p><input name="incldead" value="true" type="checkbox">Include Dead Torrents</p>
                                </td>
                            </tr>
                        </tbody>
                    </table>
                    </form>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="7" valign="middle" align="center"></td>
        </tr>
    </tbody>
</table>

<br clear="all" >

<?php if ($this->_rootref['S_TORRENTS']) {  ?>

<table class="tablebg" width="100%" cellspacing="0">

<tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">

<a class="c4" style="cursor: pointer;float:left;" onClick="toggle2('nnTorrents');">Torrents</a>

</div>

</div>

</div>

</td></tr>

<tr valign="middle">

<td class="row3"><div id="nnTorrents">

<table class="ttable_headinner" border="0" cellpadding="0" cellspacing="0" width="100%">

<tbody><tr>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=4&amp;type=<?php if ($this->_rootref['T_SORT'] == 'd') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Type desc">Type</a></td>

<td class="ttable_head" align="left"><a href="/torrents.php?sort=1&amp;type=<?php if ($this->_rootref['T_SORT'] == 'a') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Name asc">Name</a></td>

<td class="ttable_head" align="left">DL</td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=2&amp;type=<?php if ($this->_rootref['T_SORT'] == 'b') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Number of files desc"><img src="themes/Bitfarm/pics/completed.gif" alt="Number of Files" title="Number of Files" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/comments.png" alt="Comments" title="Comments" border="0"></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/report.gif" alt="Ratings" title="Ratings" border="0"></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=5&amp;type=<?php if ($this->_rootref['T_SORT'] == 'e') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Number of files desc"><img src="themes/Bitfarm/pics/servers.png" alt="Size" title="Size" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/completed.png" alt="Downloaded" title="Downloaded" border="0"></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=7&amp;type=<?php if ($this->_rootref['T_SORT'] == 'g') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Seeds desc"><img src="themes/Bitfarm/pics/seeders.png" alt="Seeds" title="Seeds" border="0"></a></td>

<td class="ttable_head" align="center"><a href="/torrents.php?sort=8&amp;type=<?php if ($this->_rootref['T_SORT'] == 'h') {  echo (isset($this->_rootref['T_SHORT'])) ? $this->_rootref['T_SHORT'] : ''; } else { ?>desc<?php ?>" title="Sort by Leechers desc"><img src="themes/Bitfarm/pics/leechers.png" alt="Leechers" title="Leechers" border="0"></a></td>

<td class="ttable_head" align="center"><img src="themes/Bitfarm/pics/peers.gif" alt="addedby" title="addedby" border="0"></td>

</tr>

<?php $_torrent_var_count = (isset($this->_tpldata['torrent_var'])) ? sizeof($this->_tpldata['torrent_var']) : 0;if ($_torrent_var_count) {for ($_torrent_var_i 0$_torrent_var_i $_torrent_var_count; ++$_torrent_var_i){$_torrent_var_val = &$this->_tpldata['torrent_var'][$_torrent_var_i]; ?>

<tr class="t-row">

<td class="ttable_col1" align="center"><br><a href="/torrents.php?cat=<?php echo $_torrent_var_val['CAT_ID']; ?>"><?php echo $_torrent_var_val['CATEGORY']; ?></a></td>

<td class="ttable_col2" nowrap="nowrap" align="left">

  <nobr>

    <p class="title">

       <nobr>

      <?php if ($_torrent_var_val['NUKED']) {  ?><img src="themes/Bitfarm/pics/nuked.gif" alt="NUKED TORRENT" title="NUKED TORRENT" border="0"><?php } if ($_torrent_var_val['FREE_DL']) {  ?><img src="themes/Bitfarm/pics/magic.gif" alt="FREE TORRENT" title="FREE TORRENT" border="0"><?php } if ($_torrent_var_val['DHT_INABLED']) {  ?><span class="overlib" onMouseOver="return overlib('This torrent supports DHT. With a state-of-the-art client, you\'ll be able to download this torrent even if a central tracker goes down.',CAPTION, 'DHT Support',TEXTFONT,'Verdana',TEXTCOLOR,'#FFFFFF',CAPTIONFONT,'Lucida Console, Verdana',LEFT,FGCOLOR,'#000000',BGCOLOR,'#6F7578',CAPICON,'themes/Bitfarm/pics/help.gif',BORDER,2,SHADOW,SHADOWOPACITY,40,SHADOWCOLOR,'#030303',SHADOWX,2,SHADOWY,2);" onMouseOut="return nd();" style="cursor: help;">

      <img src="themes/Bitfarm/pics/dht.gif" alt="" title="" border="0"></span><?php ?>

      <br />

      <b><a style="text-decoration: none;" href="details.php?id=<?php echo $_torrent_var_val['ID']; if ($this->_rootref['HIT_COUNT']) {  ?>&amp;hit=1<?php ?>" title="<?php echo $_torrent_var_val['FULL_NAME']; ?>"><?php echo $_torrent_var_val['SHORTNAME']; ?></a></b>

      </nobr></p><i><u>Added: <?php echo $_torrent_var_val['DATE_ADDED']; ?></u></i>

      </nobr><br>

      <?php if ($_torrent_var_val['BANNED']) {  ?><img src="themes/Bitfarm/pics/banned.png" alt="Banned torrent" title="Banned torrent" border="0"><?php } if ($_torrent_var_val['CAN_EDIT']) {  ?><a href="edit.php?id=<?php echo $_torrent_var_val['ID']; ?>"><img src="themes/Bitfarm/pics/edit.gif" alt="Edit" title="Edit" border="0"></a><?php } if ($_torrent_var_val['CAN_DEL']) {  ?><a href="edit.php?op=delete&amp;id=<?php echo $_torrent_var_val['ID']; ?>"><img src="themes/Bitfarm/pics/drop.gif" alt="Delete" title="Delete" border="0"></a><?php } if ($_torrent_var_val['CAN_BAN']) {  ?><a href="edit.php?op=ban&amp;id=<?php echo $_torrent_var_val['ID']; ?>"><img src="themes/Bitfarm/pics/ban.png" alt="Ban Torrent" title="Ban Torrent" border="0"></a><?php } if (! $_torrent_var_val['LOCAL_T']) {  if ($_torrent_var_val['REFRESH_T']) {  ?><a href="scrape-external.php?id=<?php echo $_torrent_var_val['ID']; ?>&amp;tracker=<?php echo $_torrent_var_val['TRACKER_URL']; ?>&amp;return=torrents.php"><img src="themes/Bitfarm/pics/refresh.png" alt="Refresh Peer Data" title="Refresh Peer Data" border="0"></a>

      <?php } else { ?><img src="themes/Bitfarm/pics/refresh_gray.png" alt="Stats Updated less than 30min ago" title="Stats Updated less than 30min ago" border="0"><?php } } if ($_torrent_var_val['NEED_AUTH']) {  echo $_torrent_var_val['AUTH_LINK']; } ?>

     

</td>

<td class="ttable_col1" align="center"><br><?php if ($_torrent_var_val['CAN_DOWN_LOAD']) {  ?><a class="index" href="download.php?id=<?php echo $_torrent_var_val['ID']; ?>"><img style="border: medium none ;" alt="download" src="themes/Bitfarm/pics/download2.gif" align="center"></a><?php ?></td>

<td class="ttable_col2" align="center"><br><a href="/torrents.php?sort=2&amp;type=desc" title="Sort by Number of files desc"><?php echo $_torrent_var_val['NUM_FILE']; ?></a></td>

<td class="ttable_col1" align="center"><br><b><a href="details.php?id=<?php echo $_torrent_var_val['ID']; ?>&amp;hit=<?php echo $_torrent_var_val['ID']; ?>&amp;comm=startcomments"><?php echo $_torrent_var_val['NUM_COMENTS']; ?></a></b></td>

<td class="ttable_col2" align="center"><br><?php echo $_torrent_var_val['RATEING_PIC']; ?></td>

<td class="ttable_col1" align="center"><br><?php echo $_torrent_var_val['DOWNLOAD_SIZE']; ?></td>



<td class="ttable_col2" align="center"><br><?php echo $_torrent_var_val['TIMES_SNATHED']; ?><br><?php echo ((isset($this->_rootref['L_TIMES'])) ? $this->_rootref['L_TIMES'] : ((isset($user->lang['TIMES'])) ? $user->lang['TIMES'] : ((defined('TIMES')) ? TIMES '{ TIMES }'))); ?></td>

<td class="ttable_col1" align="center"><b><br><?php echo $_torrent_var_val['SEEDERS']; ?></b></td>

<td class="ttable_col2" align="center"><b><br><?php echo $_torrent_var_val['LEECHERS']; ?></b></td>

<td class="ttable_col1" align="center"><br><?php if ($_torrent_var_val['ANONUMUS_UPLO']) {  echo ((isset($this->_rootref['L_ANONUMUS'])) ? $this->_rootref['L_ANONUMUS'] : ((isset($user->lang['ANONUMUS'])) ? $user->lang['ANONUMUS'] : ((defined('ANONUMUS')) ? ANONUMUS '{ ANONUMUS }'))); ?> <?php } else { ?> <a href="user.php?op=profile&amp;id=<?php echo $_torrent_var_val['UPLODER_ID']; ?>"><font color="<?php echo $_torrent_var_val['UPLDER_COLOR']; ?>"><?php echo $_torrent_var_val['UPLOADERS_NAM']; ?></font></a><?php ?></td>

</tr>

<?php }} ?>

      </tr>

    </tbody>

  </table>

</div>

<br clear="all" >

<br clear="all">

  <div class="pagination">

    <span>

      <strong>Pages <?php echo (isset($this->_rootref['CURENT_PAGE'])) ? $this->_rootref['CURENT_PAGE'] : ''?>/<?php echo (isset($this->_rootref['TOTTAL_PAGES'])) ? $this->_rootref['TOTTAL_PAGES'] : ''?></strong>

    </span> • 

    <span>

      <?php if (! $this->_rootref['PREV_PAGE']) {  ?><strong>&lt;&lt;&lt;&lt;</strong><?php } else { ?><a href="torrents.php?page=<?php echo (isset($this->_rootref['PREV_PAGE'])) ? $this->_rootref['PREV_PAGE'] : ''?>">&lt;&lt;&lt;&lt;</a><?php ?>

<?php echo (isset($this->_rootref['GENERATED_PAGES'])) ? $this->_rootref['GENERATED_PAGES'] : ''?>

        <?php if (! $this->_rootref['NEXT_PAGE']) {  ?><strong>&gt;&gt;&gt;&gt;</strong><?php } else { ?><a href="torrents.php?page=<?php echo (isset($this->_rootref['NEXT_PAGE'])) ? $this->_rootref['NEXT_PAGE'] : ''?>">&gt;&gt;&gt;&gt;</a><?php ?>

        <span>

        </span>

      </span>

    </span>

  </span>

</div><tr>

<td colspan="7" valign="middle" align="center"></td>

</tr>

</td></table>

<br clear="all" >

<br clear="all">

<?php } else { ?>

<table class="tablebg" width="100%" cellspacing="0">

<tbody><tr><td>

<div class="caption">

<div class="cap-left">

<div class="cap-right">



<a class="c4" style="cursor: pointer; float: left;" onClick="toggle2('nn ');"><img title="Expand item" id="nn&nbsp;img" src="themes/Bitfarm/pics/minus.gif" alt="+"></a>&nbsp;

</div>

</div>

</div>

</td></tr><tr valign="middle">

<td class="row3">

<div id="nn&nbsp;">

<h3><?php echo ((isset($this->_rootref['L_NO_TORRENTS'])) ? $this->_rootref['L_NO_TORRENTS'] : ((isset($user->lang['NO_TORRENTS'])) ? $user->lang['NO_TORRENTS'] : ((defined('NO_TORRENTS')) ? NO_TORRENTS '{ NO_TORRENTS }'))); ?></h3>

</div>

</td></tr>

<tr>



<td colspan="7" valign="middle" align="center"></td>

</tr>

</tbody></table>

<br clear="all">

<?php } include('blocks/searchcloud.php'); ?></div>
</td></tr>
</table></tr></table>
<br clear="all" >
<?php if ($this->_rootref['U_USER']) {  ?>

<div id="footer">
  <div class="fltLeft">
<img width="13" border="0" height="13" alt="" src="themes/Bitfarm/images/icon_rss.gif"> - <a href="backend.php?op=last">Feed Info</a>
  </div>
  
<center>
Powered by
<a target="_blank" href="http://btmanager.com">BTManager™</a>&nbsp;
 <!-- COPYRIGHT NOTICE -->
 Generated in <?php echo (isset($this->_rootref['S_GENTIME'])) ? $this->_rootref['S_GENTIME'] : ''?> seconds
<!-- Start of StatCounter Code -->
 <script type="text/javascript">
 var sc_project=2789089;
 var sc_invisible=0;
 var sc_partition=28;
 var sc_security="7d0a2fe3";
 </script>
 </span>
 &nbsp;&nbsp;
 <span class="copyright"></span>Theme By:
 <a target="_blank" href="#MrReefe">MrReefe</a> for <a target="_blank" href="http://btmanager.com">BTManager™</a>
<center>
<a href="#top"><b>Back To Top</b></a>
</center>
</div>
</div>
</body>
</html><?php ?>
here is torrent.php

PHP Code:
<?php
/*
*------------------------------phpMyBitTorrent V 3.0.0-------------------------* 
*--- The Ultimate BitTorrent Tracker and BMS (Bittorrent Management System) ---*
*--------------   Created By Antonio Anzivino (aka DJ Echelon)   --------------*
*-------------------   And Joe Robertson (aka joeroberts)   -------------------*
*-------------               http://www.p2pmania.it               -------------*
*------------ Based on the Bit Torrent Protocol made by Bram Cohen ------------*
*-------------              http://www.bittorrent.com             -------------*
*------------------------------------------------------------------------------*
*------------------------------------------------------------------------------*
*--   This program is free software; you can redistribute it and/or modify   --*
*--   it under the terms of the GNU General Public License as published by   --*
*--   the Free Software Foundation; either version 2 of the License, or      --*
*--   (at your option) any later version.                                    --*
*--                                                                          --*
*--   This program is distributed in the hope that it will be useful,        --*
*--   but WITHOUT ANY WARRANTY; without even the implied warranty of         --*
*--   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          --*
*--   GNU General Public License for more details.                           --*
*--                                                                          --*
*--   You should have received a copy of the GNU General Public License      --*
*--   along with this program; if not, write to the Free Software            --*
*-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA --*
*--                                                                          --*
*------------------------------------------------------------------------------*
*------              ©2010 phpMyBitTorrent Development Team              ------*
*-----------               http://phpmybittorrent.com               -----------*
*------------------------------------------------------------------------------*
*--------------------   Sunday, May 14, 2010 9:05 PM   ------------------------*
*
* @package phpMyBitTorrent
* @version $Id: 3.0.0 torrents.php  2010-11-04 00:22:48 joeroberts $
* @copyright (c) 2010 phpMyBitTorrent Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License 
*
*/
if (defined('IN_PMBT'))die ("You can't include this file");
define("IN_PMBT",true);
require_once(
"common.php");
require_once(
"include/torrent_functions.php");
$user->set_lang('torrent',$user->ulanguage);
$template = new Template();
set_site_var($user->lang['BROWES']);
$cats2 genrelist2();
$wherecatina = array();
$catmain '';
if (
$user->moderator)$catmain '1';
$catmid false;
foreach(
$cats2 as $cat3)
{
    
$cat_var    =    request_var('cats' $cat3['id'],  array('0'));
    if(isset(
$cat_var))
    {
        foreach(
$cat_var as $v)
        {
        
print_r($cat_var);
            
array_push($wherecatina,$v);
        }
        
$catmid true;
    }
}
require_once(
'actb.php');
pmbt_include_templ('blocks/search_block.php''cats_var');
$sort                                            request_var('sort'0);
$type                                            request_var('type''DESC');
//die($sort);
if(!$type == 'DESC')$type 'ASC';
$orderby " ORDER BY ".$db_prefix."_torrents.evidence $type, ";//
if ($sort == 1$orderby " ORDER BY ".$db_prefix."_torrents.name $type,  ";//

if ($sort == 2){
$orderby " ORDER BY ".$db_prefix."_torrents.numfiles $type,  ";//
}
if (
$sort == 3){
$orderby " ORDER BY ".$db_prefix."_torrents.comments $type,  ";//
}
if (
$sort == 4){
$orderby " ORDER BY ".$db_prefix."_torrents.category $type,  ";//
}
if (
$sort == 5){
$orderby " ORDER BY ".$db_prefix."_torrents.size $type,  ";
}
if (
$sort == 6){
$orderby " ORDER BY ".$db_prefix."_torrents.times_completed $type,  ";
}
if (
$sort == 7){
$orderby " ORDER BY ".$db_prefix."_torrents.seeders $type,  ";//
}
if (
$sort == 8){
$orderby " ORDER BY ".$db_prefix."_torrents.leechers $type,  ";//
}
        if (!isset(
$page) OR !is_numeric($page) OR $page 1$page 1;
        if (!isset(
$cat)) $cat "";
        if (
intval($cat) > 0$catwhere " AND ".$db_prefix."_torrents.category = ".intval($cat);
        else 
$catwhere "";
        
$passwhere " AND ".$db_prefix."_torrents.password IS NULL ";
        
$viswhere "visible = 'yes' AND banned = 'no'";
        if (
$user->moderator$viswhere "";
        if (
$user->premium$passwhere "";

        
$from = ($page 1) * $torrent_per_page;

        
$totsql "SELECT COUNT(*) as tot FROM ".$db_prefix."_torrents WHERE ".$catmain.$viswhere.$catwhere.$passwhere.";";
        
$sql "SELECT 
                    "
.$db_prefix."_torrents.*, 
                    IF("
.$db_prefix."_torrents.numratings < '".$minvotes."', NULL, ROUND(".$db_prefix."_torrents.ratingsum / ".$db_prefix."_torrents.numratings, 1)) AS rating, 
                    "
.$db_prefix."_categories.name AS cat_name, 
                    "
.$db_prefix."_categories.image AS cat_pic, 
                    U.username, 
                    IF(U.name IS NULL, U.username, U.name) as user_name, 
                    U.level as user_level, 
                    U.can_do as can_do, 
                    L.group_colour AS color, 
                    L.group_name AS lname 
                FROM 
                    "
.$db_prefix."_torrents 
                LEFT JOIN 
                    "
.$db_prefix."_categories ON category = ".$db_prefix."_categories.id 
                LEFT JOIN 
                    "
.$db_prefix."_users U ON ".$db_prefix."_torrents.owner = U.id 
                LEFT JOIN 
                    "
.$db_prefix."_level_settings L ON L.group_id = U.can_do 
                WHERE 
                    "
.$catmain.$viswhere.$catwhere.$passwhere.$orderby.$db_prefix."_torrents.added 
                    DESC 
                    LIMIT "
.$from.",".$torrent_per_page.";";

        
$res $db->sql_query($sql) or mysql_error();
        
$totres $db->sql_query($totsql);

if (isset(
$sort))
{
$sort1"&sort=".$sort."&type=".$type;
$sort2"?sort=".$sort."&type=".$type;
}
else
{
$sort1="";
$sort2="";
}
$t_sort = array('i','a','b','c','d','e','f','g','h');
$t_type = array('asc'=>'desc','desc'=>'asc','DESC'=>'asc','ASC'=>'desc');
        list (
$tot) = $db->sql_fetchrow($totres);
        
$db->sql_freeresult($totres);
        if (
$db->sql_numrows($res) > 0) {
                
$template->assign_vars(array(
                        
'S_TORRENTS'            => true,
                        
'T_SORT'                =>    $t_sort[$sort],
                        
'T_SHORT'                =>    $t_type[$type],
                ));
                
$pages ceil($tot $torrent_per_page);
                
generate_torrentpager('torrents.php?page='$page$pages$cat $sort1 $sort2 );
                
get_tor_vars($res);
        }
        else
        {
                        
$template->assign_vars(array(
                        
'S_TORRENTS'            => false,
                ));
        }
$template->assign_vars(array(
        
'HIT_COUNT'            => ($user->admin) ? false true,
));
echo 
$template->fetch('torrents_body.html');
    
close_out();
?>
and to Boot my source is pHp5.5.3 compliant.
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Manager™ forum
My Current Demo is here http://demo.btmanager.org/

Last edited by joeroberts; 25th September 2013 at 23:30.
Reply With Quote