View Full Version : Who Downloaded This Attachment
Psionic Vision
17 Dec 2005, 20:57
/*=============================================*\
|| Who Downloaded This Attachment
||
|| =======================================
|| Brought to you by:
|| VisionScripts (http://www.visionscripts.com/)
|| Premium PHP & vBulletin Solutions!
|| =======================================
||
|| Author : Anton Kanevsky (aka Psionic Vision)
|| Works on : vBulletin 3.5.x - 3.8.x
|| Released : Jun 27, 2009
||
|| Time required to install: ~30 seconds
|| Difficulty: easy
\*=============================================*/
DESCRIPTION
Allows users to see detailed information about who has downloaded attachments.
STATISTICS
File Uploads: 1
Products to Install: 1
FEATURES
General:
Displays a list of users with information about the number of downloads and last downloaded time.
Allows to specify which usergroups can use the feature.
VERSION HISTORY
1.1.0
[F] Fixed a bug in the product xml file.
1.1.0
[+] Officially compatible with 3.5.x - 3.8.x.
[+] Removed all file and template edits.
[+] Added usergroup permission to specify which usergroups can use the feature.
[+] The last downloaded time for each user is now displayed.
1.0.2
[F] Compatibility with 3.5.2's modified attachments.php.
1.0.1
[+] Each user now has a number of downloads displayed next to him/her.
1.0.0
First Release
The installation manual is contained within the attached file.
IF YOU LIKE MY HACK, PLEASE CLICK INSTALL (http://www.vbulletin.org/forum/vborg_miscactions.php?do=installhack&threadid=217271)
hmm..so is this like a more simple version of this hack (http://www.vbulletin.org/forum/showthread.php?t=93167) by Mr Blunt?
i'll check it out in a minute :)
- Tyler
Psionic Vision
17 Dec 2005, 21:23
Uh.. I didn't know that there was already such hack. But yeah, looks like it. less buff = better :)
JohnBee
17 Dec 2005, 21:23
Nice little addon!
Is it possible to have it display the no. of downloads?
I would like to see a link that says: Downloaded 12 times and when you click or hover on it the list would appear :)
Still... this is a good and useful idea!
well, installed perfectly, and much more simple than Mr Blunts..
/me clicks install
Psionic Vision
17 Dec 2005, 21:31
Seems like you missed the button ;)
Psionic Vision
17 Dec 2005, 21:34
Is it possible to have it display the no. of downloads?
Yes, definitely.
Psionic Vision
17 Dec 2005, 22:04
Ok, updated. Now the number is displayed.
If you have installed the hack, overwrite the XML and run this query:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
Seems like you missed the button ;)
oops :nervous:
/me clicks install and re-checks that he did this time :p
- Tyler
First of all thanks for your hack, were here for quite some time to look up.
Unfortunately I get a error when I refresh the page where the attachment is.
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
jluerken
18 Dec 2005, 00:20
The phrase "psiwd_who_downloaded" is not created automatically :D
Psionic Vision
18 Dec 2005, 00:24
First thnx for this hack,
but I have no who downloaded link and I get many errors.
This is a problem with your copy of vBulletin, not with the hack.
The phrase "psiwd_who_downloaded" is not created automatically
Thanks, fixed :)
Does it show how many times a member downloaded the same attachment? Just for antileeching you know ;)
This is a problem with your copy of vBulletin, not with the hack.
Why is this a problem of my vbulletin :ermm: , I have exactly such vbulletin as everyone other one. vB 3.5.2
jluerken
18 Dec 2005, 00:27
I added a download to the db and downloaded it three times.
See the output (attachment).
The window is not showing the user name and a 0 instead which is definetly wrong.
Psionic Vision
18 Dec 2005, 00:29
Does it show how many times a member downloaded the same attachment? Just for antileeching you know
Yes.
Why a this problem of my vbulletin is, I have exactly such vbulletin as everyone other one.
Because my hack does not go anywhere near class_core.
I added a download to the db and downloaded it three times.
See the output (attachment).
The window is not showing the user name and a 0 instead which is definetly wrong.
Can I see that on your board?
Because my hack does not go anywhere near class_core.
Oke, very vague
Uninstall is the best way at this moment :disappointed:
Oke, very vague
Uninstall is the best way at this moment :disappointed:
Its a problem with your vB copy. most likey a bug.
JohnBee
18 Dec 2005, 04:35
Dewd your .html installer is KICK ASS!!!! .thumbsup. [INSTALLED]
Rickie3
18 Dec 2005, 05:15
this is great,but one thing,is there anyway of only allowing admins/mods to view who downloaded,as everyone can view even guests
*installed* anyway very handy,installed on 3.5.0 no probs
jluerken
18 Dec 2005, 09:55
Database error in vBulletin 3.5.2:
Invalid SQL:
SELECT userid FROM attachmentviewslog
WHERE attachmentid = '21'
AND userid = '1';
MySQL Error :
Error Number :
Date : Sunday, December 18th 2005 @ 01:13:20 AM
This night I got messages from my board with the same error:
Database error in vBulletin 3.5.2:
Invalid SQL:
SELECT userid FROM vb3_attachmentviewslog
WHERE attachmentid = '817'
AND userid = '3';
MySQL Error :
Error Number :
Date : Sunday, December 18th 2005 @ 01:17:00 AM
Script : http://www.xyz.com/forum/attachment.php?attachmentid=817&d=1134864414
Referrer : http://www.xyz.com/forum/showthread.php?t=9726
There is definetly something wrong with this hack at the moment.
This night I got messages from my board with the same error:
There is definetly something wrong with this hack at the moment.
I think it also.
I have install vbulletin this week, and have no charge of other plugins.
Perhaps it is a MySQL Version problem ?
I have MySQL Version 3.23.58 stable.
jluerken
18 Dec 2005, 10:48
I think it also.
I have install vbulletin this week, and have no charge of other plugins.
Perhaps it is a MySQL Version problem ?
I have MySQL Version 3.23.58 stable.
Mine is 4.0.18 and I don't think that this is the problem
Mine is 4.0.26.
Database error in vBulletin 3.5.1:
Invalid SQL:
SELECT userid FROM attachmentviewslog
WHERE attachmentid = '8503'
AND userid = '1';
Psionic Vision
18 Dec 2005, 13:28
What is the reason for this SQL to be invalid? Does it tell you why it's invalid?
this is great,but one thing,is there anyway of only allowing admins/mods to view who downloaded,as everyone can view even guests
*installed* anyway very handy,installed on 3.5.0 no probs
If you disable "thread view" permissions for guests, then they won't be able to look. Otherwise, they will.
What is the reason for this SQL to be invalid? Does it tell you why it's invalid?
This is the only warning that I gets:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
I have vBulletin Version 3.5.2 and my class_core.php are orgineel
Psionic Vision
18 Dec 2005, 14:17
Do you have that problem with the product XML disabled?
And what type of attachment are you trying to download when this happens?
EDIT: Fixed. In 3.5.2, attachment.php was modified and I had to move the code to a different hook. Now it's working properly in 3.5.2 :)
Installed again, but there happened nothing if I download my zip file.
Also it do not counted the views.
(see first screen)
When I turn off the plugin, then I see the Who Downloaded? text, but I get also a page with the Generic Smilies code's :eek:
(see second screen)
Psionic Vision
18 Dec 2005, 19:25
Try UNINSTALLING the hack, and the installing it again.
Or, when you install, make sure to check "ALLOW OVERWRITE".
There is NO way for it to NOT work, because I just installed it on a new vbulletin 3.5.2 board, and it works perfectly.
Try UNINSTALLING the hack, and the installing it again.
Or, when you install, make sure to check "ALLOW OVERWRITE".
There is NO way for it to NOT work, because I just installed it on a new vbulletin 3.5.2 board, and it works perfectly.
Oke on my clean testboard i get now this error in the Who Downloaded popup when i push on the Who Downloaded link:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
New attachments are fine. But with old attachments there are errors:
Database error in vBulletin 3.5.1:
Invalid SQL:
SELECT userid FROM attachmentviewslog
WHERE attachmentid = '8470'
AND userid = '72';
MySQL Error :
Error Number :
Date : Sunday, December 18th 2005 @ 01:48:14 PM
Script : http://www.domain.com/forums/attachment.php?attachmentid=8470&stc=1&d=1131814178
Referrer : http://www.domain.com/forums/showthread.php?t=2604
IP Address : xx.xx.xx.xx
Username : xxxx
Classname : vb_database
Psionic Vision
18 Dec 2005, 22:26
drl2005
That is strange. Try uninstalling the product and reinstalling it again.
You should have that table in your DB after you install the XML.
dan35
Make sure you have uninstalled the old product XML before you install the new one.
drl2005
That is strange. Try uninstalling the product and reinstalling it again.
You should have that table in your DB after you install the XML.
3 time uninstalled and installed, but it remains the same.
Can you give me the table so that I can put it in my database without the xml file.
Rickie3
19 Dec 2005, 05:58
If you disable "thread view" permissions for guests, then they won't be able to look. Otherwise, they will.hmmmm not quite what i was after,i dont want to disable thread viewing for guests,only want to disable viewing of who downloaded from guests
Psionic Vision
19 Dec 2005, 11:26
I'll see if I add a who downloaded usergroup permission in next version.
As for MySQL error - make you delete the whodownloaded plugin located at attachment_complete hook.
Rickie3
19 Dec 2005, 11:34
I'll see if I add a who downloaded usergroup permission in next version.
thankyou look forward to it,keep up the good work :up:
As for MySQL error - make you delete the whodownloaded plugin located at attachment_complete hook.
Sorry, but I get not entirely what your meant
nuxvirg
22 Dec 2005, 12:08
SQL sorgusu:
ALTER TABLE attachmentviewslog ADD count INT( 10 ) UNSIGNED NOT NULL DEFAULT '1'
MySQL çıktısı: Yardım
#1146 - Table 'gerha_forum.attachmentviewslog' doesn't exist
Psionic Vision
22 Dec 2005, 19:50
If you have a table prefix defined, then you need to prepend "attachmentviewslog" with that table prefix before you run the query.
I have run the query manual, and now everything works perfectly :)
Only I do not understand why the query not running out with the xml file.
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
Psionic Vision
22 Dec 2005, 21:03
I don't know why. Prolly cause it has a ; at the end, and vb 3.5 has a problem with that :p Will check
Very nice, thanks ;)
File attach: French Language :)
Psionic Vision
22 Dec 2005, 21:12
Why would you attach the whole XML? How about language only?
silurius
05 Jan 2006, 21:54
I upgraded to 3.5.3 yesterday, and began installing this today. As soon as I edited vbulletin_global.js, my forum and admincp performance dropped significantly, I was unable to open a template and I could no longer expand groupings in the admincp navigation. I rolled back the vbulletin_global.js change, and instantly these problems disappeared. Should mention that I also installed Johannes' Who viewed this thread (http://www.vbulletin.org/forum/showthread.php?t=91409) plugin a few minutes previously (and have not removed).
Any ideas?
Psionic Vision
05 Jan 2006, 22:00
Maybe you have done the .js edits incorrectly? There is absolutely NOTHING in the .js that could slow down your admincp's performance. It is essentially simply a copy-paste-modify of another piece of vBulletin code...
silurius
06 Jan 2006, 02:28
Maybe you have done the .js edits incorrectly? There is absolutely NOTHING in the .js that could slow down your admincp's performance. It is essentially simply a copy-paste-modify of another piece of vBulletin code...Gah, it appears this is the case, the problem lay between the keyboard and my chair. To be totally fair, I assign partial blame to the scrolling codeboxes in the readme.html, but no worries. :)
Works beatifully.
steadicamop
08 Jan 2006, 20:05
Installed, a wonderful addition, although doesn't seem to work in FireFox, just makes the page scroll up to the top, but does work in IE - is this correct?
After my forum's been upgraded from 3.5.1 to 3.5.3, this hack doesn't work with firefox.
oops, nevermind, it works fine now!
Thx!
alluidh
28 Mar 2006, 20:08
Hi
Is it possible to use this hack in one or two forum only? Normaly the member can download what they want, but in a special area of my webproject I need to see who downloaded and when did he/she download the file. This will be a part of a little workflow.
Thanks for answer
Psionic Vision
08 Apr 2006, 00:48
No, it is not currently possible.
Works like a charm!
/me clicks Install!
Out of almost 2 dozen Mods/Hacks that I've installed, this is the first one using that html-based "check-off" list - love it!
Installed, a wonderful addition, although doesn't seem to work in FireFox, just makes the page scroll up to the top, but does work in IE - is this correct?
Worked for me in both browsers... The only time it "jumped to the top" was when an attachment had NOT been downloaded since the time this mod had been installed - it's not "retroactive"
MaLTRaiN
11 Apr 2006, 16:52
Are there a hack retroactive in this??? Thanks...
Psionic Vision
11 Apr 2006, 17:03
No, it's not. You cannot see history before this installation.
I've tried this hack on version 3.5.4 and it only enters the username of the first person who has downloaded the attachment. If another user downloads it, that name is not added to the list. The download counter is not updated neither.
It seems to work for images, but not for other files.
What could be causing this?
Psionic Vision
29 Jun 2006, 23:00
Improper installation of the hack, as always.
First improper install out of the 10 i have installed :P
I have followed all the steps. Does it perhaps take some time before it updates.
Psionic Vision
29 Jun 2006, 23:27
Then perhaps it does not work properly with 3.5.4, I'll verify.
Another thing that i've noticed is that the pop-up for "who has downloaded" does not work in mozilla firefox (it does work in IE). It simply scrolls the page back to the top. Thanks for the quick support btw.
MaLTRaiN
26 Jul 2006, 15:56
This mod will be updated for 3.5.4?
brvheart
28 Aug 2006, 04:12
I had 3.5.4 and 3.5.5 running on old borad...this worked fine in both.
Nice simple Q. Is this good in 3.6 ? :)
brvheart
11 Sep 2006, 18:19
Nice simple Q. Is this good in 3.6 ? :)
My thought as well...I sure hope so :)
Psionic Vision
11 Sep 2006, 20:13
Not so simple. I don't know. Haven't tested. But it SHOULD work.
brvheart
12 Sep 2006, 01:54
thx PV :)
Keyser Söze
16 Sep 2006, 01:07
has this been tested in 3.6.1?
thanks
-edit- installed on 3.6.1 but it does not work, no errors tho, u can see it here
http://www.emuasylum.com/forums/showthread.php?t=38116
daloosaa
05 Oct 2006, 21:13
Great Mod,
works fine with vBulletin 3.6.2. No errors.
perfphysio
07 Oct 2006, 18:01
You mention in your install direction to find:
<phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase> in the postbit_attachment template.
The code in that template in 3.6.2 reads:
<if condition="$show['views']">, <phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase></if>)
Where exactly do we place the code, efter the final bracket, after the close of the phrase, or somewhere else? I am not a coder so I need direction on whether it is as you describe and should be after the close of the phrase or should it be after the </if>) ?
Humm i not understand but this hack don't work on my forum with vB3.6.2, but work with 3.6.0 ....:confused:
brvheart
26 Oct 2006, 14:55
Working on my 3.6.1
brvheart
26 Oct 2006, 15:01
You mention in your install direction to find:
<phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase> in the postbit_attachment template.
The code in that template in 3.6.2 reads:
<if condition="$show['views']">, <phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase></if>)
Where exactly do we place the code, efter the final bracket, after the close of the phrase, or somewhere else? I am not a coder so I need direction on whether it is as you describe and should be after the close of the phrase or should it be after the </if>) ?
I tried mine both before and after, did not seem to make a difference if it was placed before or after...
kartik786
02 Apr 2007, 16:53
Any idea when upgrade will be released for 3.6.4 ??
Doesnt work on it. Produces lot of internal server errors :(
BANDiT600
06 Apr 2007, 20:42
Yeah, we would like new one for 3.6.4 and higher... ;)
Makc666
09 Apr 2007, 18:17
Any idea when upgrade will be released for 3.6.4 ??
Doesnt work on it. Produces lot of internal server errors :(
Yeah, we would like new one for 3.6.4 and higher... ;)
Works fine on 3.6.4 and on 3.6.5
Psionic Vision
09 Apr 2007, 19:23
Yeah.... Internal Server Errors have nothing to do w/ this particular hack.
works perfect on fresh copy of vb3.6.8
infact did only take a min to install :)
cheers Psionic for this hack
Direct Vision
25 Oct 2007, 10:00
i installed this modification and the view who downloaded appears, but when i press on it the page goes up and it doesn't show you who downloaded.
I am using vb 3.6.8,
can anyone help me please??
perfphysio
25 Oct 2007, 11:15
i installed this modification and the view who downloaded appears, but when i press on it the page goes up and it doesn't show you who downloaded.
I am using vb 3.6.8,
can anyone help me please??This happens nearly every time that one updates vbulletin with this mod. This is because part of the hack involves a custom edit of one of the global js templates. (./clientscript/vbulletin_global.js)
If you edit that file again as shown in the instructions then this should fix the issue
Direct Vision
25 Oct 2007, 11:25
ok mate i try it
Direct Vision
25 Oct 2007, 11:45
what software or programm i need to open and edit . js file??
Direct Vision
25 Oct 2007, 13:30
i edited the vbulletin_global and still the same problem and i reinstall the hack but still no joy.
the page give this error when i press the who downloaded? botton
Line : 824
Char :1
Error : object exected
Code ; 0
can you help with this please?
Direct Vision
25 Oct 2007, 14:15
This Is what i edited :
vbulletin_global.js
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
In modifyattachmentsbit :
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
And in postbit_attachment :
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
And then i installed the hack.
Can you tell me what i did wrong??
haytham
02 Nov 2007, 12:15
i installed this modification and the view who downloaded appears, but when i press on it the page goes up and it doesn't show you who downloaded.
I am using vb 3.6.8,
can anyone help me please??
Same here and I am sure I did all the edits correctly including the vbulletin_global.js. Any ideas?
haytham
02 Nov 2007, 12:28
My bad. I was working on 2 forums and got mixed up. Working fine. Installed.
Cybershaolin
25 Nov 2007, 19:19
Does not work with Firefox. I get this link: http://www.myforum.com/forum/showthread.php?t=7714#
But when I click on it nothing happens. It just brings the page to the top. All my edits are OK. Hack was working with 3.6.7. Yes the js file was re-edited as well after upgrading to 3.6.8.
Using Firefox 2.0.0.9. Working fine with IE 7. Any way to make it work with Firefox?
haytham
26 Nov 2007, 21:33
Does not work with Firefox. I get this link: http://www.myforum.com/forum/showthread.php?t=7714#
But when I click on it nothing happens. It just brings the page to the top. All my edits are OK. Hack was working with 3.6.7. Yes the js file was re-edited as well after upgrading to 3.6.8.
Using Firefox 2.0.0.9. Working fine with IE 7. Any way to make it work with Firefox?
Had this issue but found it connected to java. Try to disable the java and see.
FCS-Webmaster
17 Jan 2008, 23:47
Installed and works like a charm on vb 3.6.8.
exportforce
19 Feb 2008, 16:40
How can I change it so that only Admin can see the new link ?
edit:
Okay, found out.
Please add this to the manual as optional step:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
instead of
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
Just instead of 6, 7, 9 the Number of the Usergroups you want to use.
You can also use less or more groups, not restricted :)
MarahibSat
25 Feb 2008, 22:30
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
thx exportforce, I did these changes but still didn't work for me here is what I have in my whodownloaded templates, who can show me where to put exportforce codes so can be limited to some usergroups, thx in advance
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
exportforce
29 Feb 2008, 16:24
As I wrote, instead of inserting:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
(Thats what you would normally add)
you take THIS:
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
And instead of 6, 7, 9 put your usergroup ID's into the code :)
Hmm, installed it all correctly on 3.6.8 but it's not showing who downloaded it..
J98680Bxxxxx
09 Apr 2008, 13:04
Installed and working fine on vB 3.7 RC2 :up:
Actually, in vB UserCP there is a link "Attachments" which lists all attachments uploaded by a user.
Any idea how we could extend this mods in order to display the list of attachments downloaded by a given user in his/her UserCP?
Thanks in advance for any hint. I have been looking at the source code for the file misc.php, but cannot figure out how to proceed. :(
somasimple
18 Jun 2008, 06:06
Hi all,
I was unable to find the code below in global.js
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------
J98680Bxxxxx
18 Jun 2008, 06:49
Hi all,
I was unable to find the code below in global.js
...
You may want to checkout this mod (http://www.vbulletin.org/forum/showthread.php?t=93167) instead.
:up:
somasimple
18 Jun 2008, 08:18
I need a hack that functions with 3.7.1 PL1
yahoooh
04 Aug 2008, 09:20
any one can confirm if it is working with vb 3.7
Makc666
11 Aug 2008, 07:49
any one can confirm if it is working with vb 3.7
Yes, it works.
sateurope
08 Sep 2008, 08:00
No longer working with last update.
Global JS is altered and needed text to find is no longer there:confused:
haytham
23 Sep 2008, 12:06
Well...any fixes?
perfphysio
15 Oct 2008, 20:06
is there an upgrade for 3.7.3. It seems the ./clientscript/vbulletin_global.js is now somewhat different.
somasimple
16 Oct 2008, 05:49
This one works with 3.7.3 (tested)
http://www.vbulletin.org/forum/showthread.php?t=93167
perfphysio
16 Oct 2008, 08:43
Many thanks Bernard :)
AnotherJacob
18 Feb 2009, 20:48
is this working for v3.8.1 ?
Fraxter
22 Mar 2009, 15:20
is this working for v3.8.1 ?
Yes it works.
@PV: An option which enables the exact download time would be very usefull. :)
Hornstar
15 Apr 2009, 04:16
I don't think this one is optimized for 3.8.x anymore. Is anyone interested in taking over this if the coder has stopped supporting it?
Fraxter
27 Jun 2009, 17:59
Thanks a lot for this great update. :) :up:
Почему в настройках групп пользователей что бы включить этот модуль, его надо выключить?
vBulletin® v3.6.12, Copyright ©2000-2012, Jelsoft Enterprises Ltd.