vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=246)
-   -   Show Thread Enhancements - add Download Button next to attachments (https://vborg.vbsupport.ru/showthread.php?t=293875)

Mohammad Kamal 01-11-2013 11:00 PM

add Download Button next to attachments
 
1 Attachment(s)
Hello,

Add Download Button next to attachments

I posted the same thread but for vBulletin 3 here

https://vborg.vbsupport.ru/showthread.php?p=2396524

and now here is it for vBulletin 4

Screenshot:

https://vborg.vbsupport.ru/attachmen...1&d=1358033019

To do that, open postbit_attachment template

Search for:

Code:

({vb:raw attachment.filesize}<vb:if condition="$show['views']">, {vb:rawphrase x_views, {vb:raw attachment.counter}}</vb:if>)
below it add:

Code:

<a class="downloadbutton_attachments" href="attachment.php?{vb:raw session.sessionurl}attachmentid={vb:raw attachment.attachmentid}&amp;d={vb:raw attachment.dateline}"<vb:if condition="$show['newwindow']"> target="_blank"</vb:if>>Download</a>
then open additional.css template and add the following code:

Code:

/* ***** Download Button for attachments by Mohammad Kamal */
.downloadbutton_attachments{
color: black;
font-size: 8pt;
font-family: tahoma;
border: solid 1px;
padding: 3px;
text-decoration: none;
background-color: #DDD;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}
a.downloadbutton_attachments:link { color: black; }
a.downloadbutton_attachments:hover { color:red; }

You can edit the color as you like!

and that's it, Enjoy ;)

Krusty1231 01-12-2013 11:48 PM

1 Attachment(s)
I like it, however I get a strange reaction when adding the CSS. It changes the colors of certain areas of my skins. Is it just me?

Mohammad Kamal 01-13-2013 06:29 AM

Quote:

Originally Posted by Krusty1231 (Post 2396543)
I like it, however I get a strange reaction when adding the CSS. It changes the colors of certain areas of my skins. Is it just me?

ya that's right, I just edited the CSS code above, replace it please

Krusty1231 01-13-2013 06:40 AM

Much obliged Sir. Works Great! Thank you.

Dorgham 03-05-2013 12:30 AM

Thanks Mohamed
superb when downloading attachments :)

chuckhodson 03-05-2013 04:58 AM

Works great thanks man...

dizzynation 03-06-2013 03:03 AM

Works perfect. Great work!

ahmed-samara 03-10-2013 09:56 PM

Works great thanks man

vimarc 03-18-2013 10:53 AM

I tried on 4.2.0 but not working

stevieb 08-03-2013 09:49 AM

Quote:

Originally Posted by vimarc (Post 2410752)
I tried on 4.2.0 but not working

I thought this was for vB 4.2.0?

Can anyone confirm if it works on 4.2.0 please


All times are GMT. The time now is 07:18 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.01947 seconds
  • Memory Usage 1,729KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete