Activity Stream
48,167 MEMBERS
6961 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1.     
    #1
    Member

    Post how to display torrent tracker ratio in the navbar or header

    hi i want to know how can i display torrent tracker ratio in the navbar or header like this
    maverick79 Reviewed by maverick79 on . how to display torrent tracker ratio in the navbar or header hi i want to know how can i display torrent tracker ratio in the navbar or header like this http://desmond.imageshack.us/Himg259/scaled.php?server=259&filename=ratiok.jpg&res=medium Rating: 5

  2.   Sponsored Links

  3.     
    #2
    Banned
    do you own the tracker or not?

    if yes,do you want to make it appear in the navbar of all users right?make your question clear

  4.     
    #3
    Member
    @sceneguy yes i own a tracker and i want the ratio to appear in the navbar of all users

  5.     
    #4
    Banned
    i dont know how the script works,basically,you have to do this
    i`m assuming the navbar is not present atm ..if its already present,skip this part
    Code: 
    $result=mysql_query(SELECT * FROM users WHERE id='id');
    $r=$result['u']/$result['d']
    echo 'upload:'.$result['u'].'download:'.$ratio['d']
    echo 'ratio:'.$r;
    if its already present,you just want to modify it,then ask some designer.i know 0% about designing.learning php atm



    Thats just the pseudo code.match it for your system.if you need help,pm and we`ll see how to go forward

  6.     
    #5
    Member
    What front-end are you using for your site?
    This is the staff, you have been banned

  7.     
    #6
    Member
    Quote Originally Posted by snowmanrene View Post
    What front-end are you using for your site?
    vbulletin

  8.     
    #7
    Member
    any more views?

  9.     
    #8
    Member
    Are you using vBitty?
    What version of vBulletin? 3/4?
    This is the staff, you have been banned

  10.     
    #9
    Member
    yes iam using vbitty with vbulletin 3.8.5

  11.     
    #10
    Member
    I don't use vB so not too sure, but are you allowed to add php code to the template files?
    If you can, try adding this where you want it displayed:

    PHP Code: 
    <?php
    /**
     * vBitty (VBTT) 3 XBT v1.2 SVN
     * Coded by Toolmanwill
     **/ 

    // get user ratio & display it in various colors

             
    if ($userinfo["downloaded"])
            {
              
    $ratio $userinfo["uploaded"] / $userinfo["downloaded"];
              if (
    $ratio 0.1)
                
    $s "<font color=#ff0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.2)
                
    $s "<font color=#ee0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.3)
                
    $s "<font color=#dd0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.4)
                
    $s "<font color=#cc0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.5)
                
    $s "<font color=#bb0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.6)
                
    $s "<font color=#aa0000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.7)
                
    $s "<font color=#990000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.8)
                
    $s "<font color=#880000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 0.9)
                
    $s "<font color=#770000>" number_format($ratio2) . "</font>";
              else if (
    $ratio 1)
                
    $s "<font color=#660000>" number_format($ratio2) . "</font>";
              else
                
    $s =  number_format($ratio2) ;
            }
            else
            {
              if (
    $userinfo["uploaded"])
                
    $s "Inf.";
              else
                
    $s "---";
            }
    $agents $db->query("SELECT useragent FROM "TABLE_PREFIX ."peers WHERE uid = '".$userinfo['userid']."'");
    $agent $db->fetch_array($agents);
     
    if (
    $vbulletin->options['vbtt_show_speeds'])
           {
    $uspeeds $db->query("SELECT SUM(upspeed) as ulspeedtot ,SUM(downspeed) as dlspeedtot FROM "TABLE_PREFIX ."peers WHERE uid = '".$userinfo['userid']."'");
    $uspeed $db->fetch_array($uspeeds);   
    $ulspeedtot $uspeed['ulspeedtot'];
    $dlspeedtot $uspeed['dlspeedtot'];

            if (
    $ulspeedtot =="0")
                
    $ulspeed "<font color=red>".mksize($ulspeedtot1true)."/s"."</font>";
            else 
    $ulspeed "<font color=green>".mksize($ulspeedtot1true)."/s"."</font>";
            
                if (
    $dlspeedtot =="0")
                
    $dlspeed "<font color=red>".mksize($dlspeedtot1true)."/s"."</font>";
            else 
    $dlspeed =  "<font color=#4169e1>".mksize($dlspeedtot 1true)."/s"."</font>";
         }
            
    $userinfo['downloaded'] = "<font color='#4169e1'> ".mksize($userinfo["downloaded"], 1true)."</font>";
    $userinfo['uploaded']= "<font color='green'>".mksize($userinfo["uploaded"], 1true)."</font>";
    $userinfo['dlspeed'] = $dlspeed;
    $userinfo['ulspeed'] = $ulspeed;
    $userinfo['ratio']= $s ;
    $userinfo['btclient'] = $agent[useragent];

    ?>
    This is the staff, you have been banned

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Need a vps for a torrent tracker
    By iq2011 in forum Hosting Discussion
    Replies: 19
    Last Post: 7th Feb 2012, 08:03 PM
  2. Best XXX torrent tracker
    By viruz99 in forum General Discussion
    Replies: 4
    Last Post: 22nd Oct 2011, 02:37 PM
  3. Torrent & Ratio Question
    By StyXoN in forum General Discussion
    Replies: 10
    Last Post: 3rd Oct 2011, 04:09 PM
  4. Whats the best torrent site without ratio issues
    By Shagrath in forum General Discussion
    Replies: 11
    Last Post: 2nd May 2011, 05:02 PM
  5. Header does't display correctly on difference resolutions. Vb4
    By Nicol in forum Technical Help Desk Support
    Replies: 3
    Last Post: 20th Sep 2010, 05:50 PM

Tags for this Thread

BE SOCIAL