Go Back   vb.org Archive > vBulletin Modifications > Archive > Modification Graveyard

Reply
 
Thread Tools
Upload/Download Stats in Postbit Details »»
Upload/Download Stats in Postbit
Version: 1.00, by tnguy3n tnguy3n is offline
Developer Last Online: Sep 2010 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 3.0.5 Rating:
Released: 01-13-2005 Last Update: Never Installs: 18
DB Changes
 
No support by the author.

Upload/Download & Total Upload/Download stats

Requested here

Modded by tnguy3n (Thinh Nguyen)
Live Demo: http://www.all4actions.net

Description: This mod display total filesize and number of upload/download in postbit.
I've tested it in vb3.0.1, 3.0.3 and 3.0.5.

New queries: 1
File Mod: 3
Template mod: 3
Installation Time: 4-5 mins

Note: make sure to run the query in phpMyAdmin or it will get an error.

Please click "INSTALL" if you use the hack. :nervous:

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 01-14-2005, 05:07 PM
lasto lasto is offline
 
Join Date: Jan 2002
Posts: 1,514
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ChrisSy
you installed and works fine?
Well downloads works but for me im having problems still as its counting up 3 for every 2 files i upload + the KB aint matching up.

So far ive uploaded 28 small rar files but it thinks ive upped 56
Download bit seems fine by what i can tell.
Reply With Quote
  #13  
Old 01-14-2005, 09:04 PM
kudos kudos is offline
 
Join Date: Jan 2005
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm having a bit of a problem, don't know if anyone can help? I can't semm to get it to work at all as I recieve the error message below when running the first query...

"An error occurred while attempting to execute your query. The following information was returned.
error number: 1146
error desc: Table 'myforumsname.user' doesn't exist"

Any help would be appreciated
Reply With Quote
  #14  
Old 01-15-2005, 08:45 AM
Lethal Lethal is offline
 
Join Date: Feb 2002
Location: PA/USA
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice forums u have there
Reply With Quote
  #15  
Old 01-15-2005, 07:58 PM
tnguy3n's Avatar
tnguy3n tnguy3n is offline
 
Join Date: May 2003
Location: U of I, Iowa
Posts: 846
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

sorry guys, my mysql server on localhost ain't let me upload files bigger than 600 KB (get error says localhost server has been gone for any big file ) and I can't test those big uploaded files now. I'll check with my *nix server and fix that upload stats problem.
Reply With Quote
  #16  
Old 01-15-2005, 11:03 PM
lasto lasto is offline
 
Join Date: Jan 2002
Posts: 1,514
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by tnguy3n
sorry guys, my mysql server on localhost ain't let me upload files bigger than 600 KB (get error says localhost server has been gone for any big file ) and I can't test those big uploaded files now. I'll check with my *nix server and fix that upload stats problem.
cheers m8
Reply With Quote
  #17  
Old 02-16-2005, 04:29 AM
Joe Pimms Joe Pimms is offline
 
Join Date: Jan 2005
Location: Canada
Posts: 95
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey nice hack i did a little moding and i made one for the memberslist area aswell the only problem im having is the data base hope u can help here is the template code for the memberslist display.

PHP Code:
Edit MEMBERLISTlook for this :

<if 
condition="$show['emailcol']"><td class="thead" nowrap="nowrap">$vbphrase[contact]</td></if>

and 
replace with :
<
td class="thead">File Upload</td>
<
td class="thead">Total Uploaded in (KB)</td>
<
td class="thead">File Download</td>
<
td class="thead">Total Download in (KB)</td>

<if 
condition="$show['emailcol']"><td class="thead" nowrap="nowrap">$vbphrase[contact]</td></if> 
then:

PHP Code:
Edit memberlist_resultsbitlook for this :

<
td class="alt1Active" align="$stylevar[left]id="u$userinfo[userid]">
        <
a href="member.php?$session[sessionurl]u=$userinfo[userid]">$userinfo[musername]</a>
        <if 
condition="$show['usertitlecol']"><div class="smallfont">$userinfo[usertitle]</div></if>
    </
td>


and 
replace with :

<
td class="alt1Active" align="$stylevar[left]id="u$userinfo[userid]">
        <
a href="member.php?$session[sessionurl]u=$userinfo[userid]">$userinfo[musername]</a>
        <if 
condition="$show['usertitlecol']"><div class="smallfont">$userinfo[usertitle]</div></if>
    </
td>
<
td class="$bgclass">$numupload</td>
<
td class="$bgclass">$uploadtotal</td>
<
td class="$bgclass">$numdownload</td>
<
td class="$bgclass">$totaltotal</td
if u can come up with the code to work in memberlist.php that would be awsome, im useing this one here:

PHP Code:
        $getuserstats $DB_site->query("SELECT * FROM " TABLE_PREFIX "user WHERE userid = $post[userid]");
        while (
$userstats $DB_site->fetch_array($getuserstats)) {
            
$numupload $userstats['uploadno'];
            
$uploadtotal $userstats['uploadtotal'];
            
$numdownload $userstats['downloadno'];
            
$totaltotal $userstats['downloadtotal'];    
        } 
when i use the top code i get this error:
HTML Code:
Database error in vBulletin 3.0.6:

Invalid SQL: SELECT * FROM user WHERE userid = 
mysql error: You have an error in your SQL syntax.  Check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
well i hope u can help plus can this hack use MB and not KB ?
Reply With Quote
  #18  
Old 02-17-2005, 04:30 AM
tnguy3n's Avatar
tnguy3n tnguy3n is offline
 
Join Date: May 2003
Location: U of I, Iowa
Posts: 846
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

sorry, i haven't had time to fix the bug in upload stats yet. I'll look into it later this weekend, hopefully, as to release new updated version of the hack. :sleep:

for your query, use this following instead:
Code:
 $getuserstats = $DB_site->query("SELECT * FROM " . TABLE_PREFIX . "user WHERE userid = $userinfo[userid]");
        while ($userstats = $DB_site->fetch_array($getuserstats)) {
            $numupload = $userstats['uploadno'];
            $uploadtotal = $userstats['uploadtotal'];
            $numdownload = $userstats['downloadno'];
            $totaltotal = $userstats['downloadtotal'];    
        }
Reply With Quote
  #19  
Old 02-17-2005, 04:46 AM
Joe Pimms Joe Pimms is offline
 
Join Date: Jan 2005
Location: Canada
Posts: 95
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

sweet bro it worked with my code and your database connection worked nice

i was hoping insted of useing KB cant you use MB ?

all people need to do is edit memberlist.php and look for
PHP Code:
// format posts number
$post['posts'] = vb_number_format($post['posts']); 
and put under:

PHP Code:
$getuserstats $DB_site->query("SELECT * FROM " TABLE_PREFIX "user WHERE userid = $userinfo[userid]");
        while (
$userstats $DB_site->fetch_array($getuserstats)) {
            
$numupload $userstats['uploadno'];
            
$uploadtotal $userstats['uploadtotal'];
            
$numdownload $userstats['downloadno'];
            
$totaltotal $userstats['downloadtotal'];    
        } 
thats it for the hole hack
Reply With Quote
  #20  
Old 02-21-2005, 10:06 PM
PET's Avatar
PET PET is offline
 
Join Date: Jan 2002
Location: Timisoara/Romania
Posts: 305
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

dos this hack show Total download/uploads from the start of the counter of from the begining of the forum ?
Reply With Quote
  #21  
Old 02-21-2005, 10:08 PM
Joe Pimms Joe Pimms is offline
 
Join Date: Jan 2005
Location: Canada
Posts: 95
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yes but it is a little buggie tho
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:31 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.06460 seconds
  • Memory Usage 2,340KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (1)bbcode_html
  • (5)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete