The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Attachment download counter
I have looked but not found it yet, but see it on several forums out there.
I would like to have a counter which counts attachments. The build in does it like this: Filename (12,3 KB, 120 views) Ik would like it like this example 1: Filename (12,3 KB, downloaded 120 times) or even more beatiful (like I've seen some places) example 2: Filename (12,3 KB) This file has been downloaded 120 times. Ofcourse I could change the "views" to "downloads" in the languages and phrases section, but normal posts al also "viewed" so I'm afraid I will change the wrong "views" phrase. Furthermore the second example I would like the most. Can anyone tell me how to do this please? |
#2
|
||||
|
||||
Anybody?
|
#3
|
|||
|
|||
|
#4
|
||||
|
||||
<a href="https://vborg.vbsupport.ru/showthread.php?t=254241" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=254241</a>
|
#5
|
||||
|
||||
Thank you, but that's for 4.x and I need one for vb 3.8.x.
|
#6
|
||||
|
||||
Post the code to postbit_attachment and ill change it for you.
|
#7
|
||||
|
||||
|
#8
|
||||
|
||||
@TheWindows7Site: Great, but I would rather like a "look for this and change that" or "look for this and replace that" kind of code, so I can see what I'm doing and save it for future use.
I'm not in a hurry, so I'm already happy if you want to do that for me. Here is my postbit_attachment: Code:
<tr> <td><img class="inlineimg" src="$stylevar[imgdir_attach]/$attachment[attachmentextension].gif" alt="<phrase 1="$attachment[attachmentextension]">$vbphrase[file_type_x]</phrase>" width="16" height="16" border="0" style="vertical-align:baseline" /></td> <td><a href="attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&d=$attachment[dateline]"<if condition="$show['newwindow']"> target="_blank"</if>>$attachment[filename]</a> ($attachment[filesize]<if condition="$show['views']">, <phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase></if>)</td> </tr> Code:
($attachment[filesize]<if condition="$show['views']">, <phrase 1="$attachment[counter]">$vbphrase[x_views]</phrase></if>)</td> </tr> Thanks! |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|