PDA

View Full Version : Most Downloaded Attachment


afterlab
04-30-2002, 10:00 PM
<font size="3">Most Downloaded Attachment</font>
Made by afterlab on April 30, 2002 for vB 2.0.3+
=========================================

Ever wondered what attachment on your forums was being downloaded the most? Well wonder no more! This hack will display the filename of the most downloaded attachment as well as a link to the attachment directly.

Compatibility: This hack will work with vB 2.0.3 and higher. This hack will also work with Attachment Viewer (a highly recommended hack made by FireFly). If you don't want Attachment Viewer, it'll also work with it.

Install Time: 1-2 Minutes

Download: Instructions are in attachment.

EchoHype.com
05-01-2002, 01:14 AM
Nice little add-on there afterlab

/me enjoys it

Velocd
05-01-2002, 01:40 AM
Sweet, but I already know our yatta song has been downloaded the most. j/k (never watch yatta o.O)
/me shivers

Crazy Mofo
05-01-2002, 02:49 AM
Very nice m8

DWZ
05-01-2002, 02:59 AM
Originally posted by Velocd
Sweet, but I already know our yatta song has been downloaded the most. j/k (never watch yatta o.O)
* DWZ shivers yatta 0wnz! :D

afterlab
05-01-2002, 03:04 AM
Thanks everyone!

BTW, what the heck is a "yatta"?

Crazy Mofo
05-01-2002, 03:12 AM
i dunno :cheeky:

Corbu
05-01-2002, 12:20 PM
Very good hack !

Thanks !

But....I don't find this ligne : $numbersregmembers....
In index.php ????????? It's very strange....

It's on vbb 2.2.5 and I try to search on vbb 2.2.2 and it's the same...

It's not : $numbersmembers... ?????

Thank you

(sorry for my english)

Crazy Mofo
05-01-2002, 01:46 PM
i didnt find it aswell so i just put it above get new posts still worked ;)

afterlab
05-01-2002, 09:25 PM
Err, sorry.. I forgot $numbersregmembers was another hack. Updated instructions.

AussieSat
05-02-2002, 12:40 PM
Good one, Afterlab.

A question or 3 if you dont mind:
Will this show the hottest attachment if it's in a private forum - I don't wish members that don't normally have permission to be able see/download it.
Can it be made to show, say, the 5 hottest attachments?
How would I make it display the thread subject rather than the file name?

Thanks - AussieSat.

afterlab
05-04-2002, 09:26 PM
Aussiesat: To make it display 5, for instance, rather than just the most popular one, use this code instead:

//Most Popular Attachment by Downloads (by afterlab)
$hotinfo=$DB_site->query_first("SELECT * FROM attachment ORDER by counter DESC LIMIT 5");
$hotinfo2=$DB_site->query_first("SELECT postid,attachmentid FROM post WHERE attachmentid=$hotinfo[attachmentid] LIMIT 5");

eval("\$hotattachment = \"".gettemplate("forumhome_hotattachment")."\";");

StealthAnime
05-05-2002, 12:12 AM
good work afterlab, greetz from .~SP_Nico~.

AussieSat
05-05-2002, 12:39 AM
Thanks Afterlab,
I had tried that (just increasing the LIMIT), but it didn't seem to work, it still only shows the first attachment. I have this running on my vBHome page (in the forum directory though) - maybe there is a problem there. Will keep trying :).

zachb
05-07-2002, 04:15 AM
/me installs hack.

very nice. i like it.

LOD-squa
11-22-2002, 11:54 PM
man your hacks are super good nice work dude

afterlab
11-23-2002, 01:20 AM
heh.. This hack is actually nothing compared to what I normally construct.

LOD-squa
11-23-2002, 02:30 AM
I know I have seen your work.

Haakon
04-29-2003, 06:44 PM
Nice, finally a small well written hack that can help me get started hacking this monster.

AussieSat: If you haven`t done it allready, the text file attached contains a solution to making the hack display the 5 hottest. Probably not the best solution, but a solution :)

corsacrazy
09-14-2003, 01:27 PM
any way to only get attachments from acertain forum id ?