Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Beta Releases

Reply
 
Thread Tools
Remote server image/attachment database hack Details »»
Remote server image/attachment database hack
Version: 1.00, by 99Percent 99Percent is offline
Developer Last Online: Jul 2013 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 06-01-2002 Last Update: Never Installs: 2
Is in Beta Stage  
No support by the author.

This is my first vBulletin hack. I have tested it only in my own vBulletin implementation. Let me know if it worked for you.

What this hack does:

I created this hack because I plan to use my vBulletin website mainly for storing and searching thousands of images that can be uploaded by many different people. Since images take up a lot of space and bandwidth I thought of a solution whereby vBulletin saves attachments on a remote database and provides links to these attachments or if images are going to be shown in messages that the remote server generates them directly to the end browser.

Another requirement is that the attachments not be available outside vBulletin itself in order to conserve the privacy of them. So what I did is create temporary permissions only provided from within vBulletin itself before requesting the files to be downloaded. These permissions are then immediately deleted by the remote server once the files are delivered. If the files are not delivered within a specified time, the permissions are automatically eliminated.

The benefit of this hack is that you will be able to provide virtually unlimited space for your attachments for almost zero cost.

What you need in order to implement this hack:

You will need a separate server from the one where you are hosting vBulletin with http, php, and mysql services. I tested the hack on MS IIS on a server connected with regular DSL.

You will need a fixed ip address or a domain name of your webserver where the images are stored. If you don't have one you can get dynamic DNS service (I use tzo.com for about $24 a year - works great).

Your vBulletin server must be able to communicate to your remote server mysql database. This is crucial.

Your remote server must be able to communicate with the vBulletin mysql database server, if not it will not be able to update the view/download count (not terribly important).

If you ISP blocks ports you might be able to get around them by using alternate ports for everything. I think the hack should be able to support alternate ports.

Steps to implement the hack:

1. First, of course, do a back up of everything

2. Apply the hacks to your current vBulletin implementation using vbHacker.php. Hacks include about 18 code alterations and 3 template alterations and no database alterations.

3. Edit the changed config.php supplying the necessary information about the remote web server and database server.

4. Upload the edited config.php to the /admin directory of the remote server.

5. Upload riattachment.php below the /admin directory of the remote server. riattachment.php is the program that delivers the attachment to the end browser, it is a heavily modified version of the original attachment.php. attachment.php is no longer used after applying the hack (I think).

6. Create the database and tables of the remote server using the createattachdb.php utility.

7. If you already have attachments stored in your vBulletin database you will need to transfer them to the remote database using the provided transferattach.php utility.

future possible enhancements to this hack:

1. Check the availability of the remote server and if not there gracefully disallow uploading of new attachments and disable viewing/downloading of attachments. I think this is important since usually the remote servers will be connected via consumer internet and will be home computers so connectivity is not going to be very stable to say the least.

2. Have the option of showing thumbnails stored at the main server and then if requested transfer the large size images stored at the remote server.

3. Store the remote database connection info in the setting table so that it can be changed from within the control panel.

4. Make a fully comprehensive install program, possibly adding the required information of the remote server to config.php directly instead of hacking it.

5. Possibly eliminate the need of fixed ip/domain name by having the remote server automatically update its ip address at the vBulletin database server each time it connects to the internet.

Show Your Support

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

Comments
  #22  
Old 02-12-2003, 03:13 PM
Martin64's Avatar
Martin64 Martin64 is offline
 
Join Date: Nov 2001
Posts: 390
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great stuff, just installed it.
Reply With Quote
  #23  
Old 03-05-2004, 09:35 PM
Bulent Tekcan Bulent Tekcan is offline
 
Join Date: Oct 2003
Location: TURKEY - Istanbul
Posts: 437
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is this hack work in VB3 RC4 ?

Thanks
Reply With Quote
  #24  
Old 04-08-2004, 07:23 PM
Bulent Tekcan Bulent Tekcan is offline
 
Join Date: Oct 2003
Location: TURKEY - Istanbul
Posts: 437
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Anybody answer me ?
Reply With Quote
  #25  
Old 09-29-2004, 12:17 AM
forumdude's Avatar
forumdude forumdude is offline
 
Join Date: Nov 2001
Posts: 50
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Has anyone released this for vb3?
Reply With Quote
  #26  
Old 09-29-2004, 01:12 PM
TCB's Avatar
TCB TCB is offline
 
Join Date: Jun 2004
Location: the Netherlands
Posts: 193
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by forumdude
Has anyone released this for vb3?
If this would be released for VB3 then it would be a dream come true. It's only a matter of time before I have to shut down the attachment option because I've ran out of webspace. I still have about 900mb left on another account, so it would be fantastic if that one could be used for the attachments.
Reply With Quote
  #27  
Old 10-29-2004, 09:39 PM
camikazi2k camikazi2k is offline
 
Join Date: Jan 2002
Posts: 49
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is there same hack but for Vb3?
Reply With Quote
  #28  
Old 10-30-2004, 08:19 PM
camikazi2k camikazi2k is offline
 
Join Date: Jan 2002
Posts: 49
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

is there one for vb3.0 same hack?
Reply With Quote
  #29  
Old 10-30-2004, 08:19 PM
camikazi2k camikazi2k is offline
 
Join Date: Jan 2002
Posts: 49
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Guess there is not.
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 06:00 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.04470 seconds
  • Memory Usage 2,276KB
  • 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
  • (1)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
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (8)postbit
  • (9)postbit_onlinestatus
  • (9)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