Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons

Reply
 
Thread Tools
Module CMPS:Recent Attachments Details »»
Module CMPS:Recent Attachments
Version: 1.01, by sinisterpain sinisterpain is offline
Developer Last Online: Nov 2013 Show Printable Version Email this Page

Category: Add-On Releases - Version: 3.6.8 Rating:
Released: 03-24-2007 Last Update: 08-08-2007 Installs: 43
Template Edits
 
No support by the author.

Module CMPS Recent Attachments


Idea was based on original hack by MindTrix

A request from a member for showing document such as text and zip files prompted me to add an additional zip file to this hack. Please be sure you download the correct file. The CMPS_recent_attachment_images.zip is for showing pictures only. The CMPS_newattachments_files.zip will display both but will only output the extension image with the file name and info (see Screenshot below).

What it does:

It will query attachments from the database for the latest 4 images or files posted, and output it to the module created on your home page. I believe I have seen this requested both here and at vBadvanced.
Will add 1 query to the home page.

Files and Templates added:

CMPS_recent_attachment_images.zip
recentattachment.php
adv_portal_newattachments

CMPS_newattachments_files.zip
newattachment.php
adv_portal_recentattachments

Tested on vb3.6.4

Installation:

1. Extract the module file from the zip to your desktop.

2. Go to your admincp->vBa CMPS->Download/Upload Module.

3. Browse to where you put the module file click submit.

4. Make sure you set all options and permisions for the module.

5. Be sure that you enable the module in your default home page or it will not show.


Change log:

version 1.00 - First release. Added additional module for files and docs.
version 1.01 - Added ability to view the members post of the image or file attachment in a new window from CMPS module.
Added update for CMPS 3.0 module
Please be sure to click installed if you want support

Show Your Support

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

Comments
  #2  
Old 03-25-2007, 08:06 PM
sinisterpain's Avatar
sinisterpain sinisterpain is offline
 
Join Date: Feb 2006
Location: New Hampshire
Posts: 571
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Reserved
Reply With Quote
  #3  
Old 03-25-2007, 08:33 PM
tehPARADOX tehPARADOX is offline
 
Join Date: Feb 2007
Posts: 112
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Any plans on displaying other attachments? such as docs & archives?
Reply With Quote
  #4  
Old 03-25-2007, 08:36 PM
sinisterpain's Avatar
sinisterpain sinisterpain is offline
 
Join Date: Feb 2006
Location: New Hampshire
Posts: 571
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by tehPARADOX View Post
Any plans on displaying other attachments? such as docs & archives?
I plan on playing around with different options so its a possibility
Reply With Quote
  #5  
Old 03-26-2007, 02:28 AM
sinisterpain's Avatar
sinisterpain sinisterpain is offline
 
Join Date: Feb 2006
Location: New Hampshire
Posts: 571
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by tehPARADOX View Post
Any plans on displaying other attachments? such as docs & archives?
Updated and added additional zip file for your request. Hopefully its what you where looking for.
Reply With Quote
  #6  
Old 03-26-2007, 02:40 AM
tehPARADOX tehPARADOX is offline
 
Join Date: Feb 2007
Posts: 112
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Wow that was fast, great job! And yes it's exactly what I was looking for.
Reply With Quote
  #7  
Old 03-26-2007, 06:36 AM
sensimilla sensimilla is offline
 
Join Date: Dec 2004
Location: Poland
Posts: 555
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Outstanding! I have almost payed for this hack ! 5 stars and MOTM

Thumbnail creation isnt perfect, they are deformed.

I would request the possibilty to
- not display file title ( with large titles it doesnt look good )
- select forum from which they should be grabbed
- select number of attachments to display

great job! keep up developing this mod!
Reply With Quote
  #8  
Old 03-26-2007, 08:09 PM
sinisterpain's Avatar
sinisterpain sinisterpain is offline
 
Join Date: Feb 2006
Location: New Hampshire
Posts: 571
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by sensimilla View Post
Outstanding! I have almost payed for this hack ! 5 stars and MOTM

Thumbnail creation isnt perfect, they are deformed.

I would request the possibilty to
- not display file title ( with large titles it doesnt look good )
- select forum from which they should be grabbed
- select number of attachments to display

great job! keep up developing this mod!
If your using the image only zip file you can adjust the size of the picture you want by editing the php file. I think I set it to 75 width 75 height. Change the code in red to what ever size you want.
Code:
[ $newattachment['attachment'] .= '<div><img class="inlineimg" src="' . $vbulletin->options['bburl'] . '/attachment.php?' . $session['sessionurl'] . 'attachmentid=' . $attachment['attachmentid'] . '" width="75" height="75">
You can also change the number of files displayed by changing the query from the current 4 to what ever you wish to display. Change the red 4 to what you want.
Code:
$query_attachments = $db->query_read("
 SELECT *
  FROM " . TABLE_PREFIX . "attachment
  WHERE visible = 1 AND dateline < " . TIME() ." ORDER BY dateline DESC LIMIT 4");
Glad you could use it. Enjoy
Reply With Quote
  #9  
Old 03-26-2007, 09:17 PM
FleaBag's Avatar
FleaBag FleaBag is offline
 
Join Date: Dec 2001
Posts: 1,674
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Brilliant, thanks!
Reply With Quote
  #10  
Old 03-27-2007, 01:17 AM
Invalid ID's Avatar
Invalid ID Invalid ID is offline
 
Join Date: Apr 2006
Location: Karachi. Pakistan
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It's just great. But there's one problem, it's also showing the attachments members using for their signature.

Also, it does not show the pictures attached using

Can you please give us one that can also work with images that are attached from some website?

Thanks
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 09:51 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05497 seconds
  • Memory Usage 2,295KB
  • Queries Executed 23 (?)
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
  • (2)bbcode_code
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)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