Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Image Cache Details »
Image Cache
Mod Version: 1.0.3.0, by y2ksw (Coder) y2ksw is offline
Developer Last Online: Jun 2019 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.5.4 Rating: (11 votes - 4.73 average) Installs: 78
Released: 07 Aug 2006 Last Update: 21 Aug 2007 Downloads: 578
Supported DB Changes Uses Plugins Additional Files  

Y2K Software Image Cache

Compatible at least with vBulletin 3.5.4 and 3.6.4

Please click here for the product Import External Images for vBulletin 4

This product caches images from external sites to a local board folder (including signatures) located at:

http://www.domain.tld/[forum/]imgcache

Installation
  1. Please create at your vBulletin board directory a folder called: imgcache and give it the following access rights: CHMOD 777 (read/write/modify to all users)
  2. Create an empty index.html file in this folder to avoid file exploring and direct download on some systems.
  3. Copy the y2kswimgcache.php file to your vBulletin board (forum home) directory.
  4. Close your forum temporarily to the public.
  5. Install the product product-y2kswimagecache.xml to your board (allow overwrite if already present).
    The installer will add a table called '[prefix]y2ksw_imgcache' with one field (int ID AUTOINCREMENT) to your board database.
    Please note: Although the uninstaller is provided, it is commented out. By removing the table, and reinstalling the plugin later, the cached images would be overwritten, because of the field counter restarting from 1.
    By leaving the table in your database, you may reinstall the plugin later without collision problems.
  6. Test the product: New thread, reply, edit. If errors occur (or white pages), make sure your imgcache/ folder has the required access rights.
  7. Reopen your forum to the public.
  8. DONE!
How it works

When a board user opens a new thread or message, or edits an existing one (all advanced, quick-reply and ajax), and pastes an image from all but the local cache directory (or by copy and paste, or by specifying [IMG] tags), upon submission the image is read from the external url and written to the local (server) image cache folder.
This avoids to show a placeholder image when the source link is dead or temporarily unavailable.

The link to the image is accordingly replaced.

The script scans first all image references and creates a table of unique images in the current message. It creates a new database table entry in y2ksw_imgcache for each image, reads the new ID and creates a sequence of new images for each url it happens to be readable, and creates for each successful read an imgcache/<id>.png file.

After this sequence, the files are cached locally and may disappear from their sources without leaving an unreferenced image pointer at the local board.

Known bugs

When an image link contains dynamic data, vBulletin would show the image in preview, but change also the IMG tags to URL.
This causes to loose the reference and the plugin will not attempt to recover. A possible solution is to allow dynamic contents for IMG tags on your board.

Version history

1.0.3.0 2007-08-19 Repaired browser (IE 7) issue for images of a different file extension than the officially recognized types. For this issue, newly cached files have now the *.png extension.
1.0.2.0 2006-08-27 Image caching of signatures ([IMG] tags for signatures must be enabled); added a donation button inside readme.htm for specific user requests, which will help us to keep this product always up-to-date.
1.0.1.2 2006-08-07 Release changes for vbulletin.org
1.0.1.1 2006-08-06 Image size verification to avoid caching of invalid images
1.0.1.0 2006-07-17 Collision-free unique cache ID's
1.0.0.0 2006-07-17 Product creation

Download Now

Only licensed members can download files, Click Here for more information.

Addons

Supporters / CoAuthors

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
  #91  
Old 18 Feb 2008, 15:28
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Originally Posted by Mazinger View Post
It does.

Plus I tried uploading the php file in ASCI and in Binary mode.

I'm using 3.6.8 pl2.

Any other clues?

... And folder name is imgcache not imagecache.

Also, I'm using IE6.
Right
Originally Posted by Mazinger View Post
Any other clues?
Sorry, no other ideas ...
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #92  
Old 18 Feb 2008, 20:12
Mazinger's Avatar
Mazinger Mazinger is offline
 
Join Date: Nov 2006
Location: Egypt
Is there any other php/server requirements/conditionals that this hack wouldn't work with?
__________________
موقع اخبار مصر واخبار الرياضة والدولار في دليل مصر
Reply With Quote
  #93  
Old 18 Feb 2008, 22:55
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Maybe if fopen() would not work. But at this point you would not be able to save attachments on your server as well.
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #94  
Old 27 Feb 2008, 08:08
Mazinger's Avatar
Mazinger Mazinger is offline
 
Join Date: Nov 2006
Location: Egypt
I just checked, and fopen() is off in the php info. Is there any way to enable it via .htaccess?
__________________
موقع اخبار مصر واخبار الرياضة والدولار في دليل مصر

Last edited by Mazinger; 27 Feb 2008 at 08:16.
Reply With Quote
  #95  
Old 27 Feb 2008, 14:37
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Not as far as I know, sorry.
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #96  
Old 16 Mar 2008, 18:01
ChurchMedia's Avatar
ChurchMedia ChurchMedia is offline
 
Join Date: Dec 2002
Real name: Tim Eason
Hi -- I've been using Image Cache since 2006. Today the imgcache folder is completely empty except for an index.html file! ALL of the images cached for almost 2 years are GONE! Does anyone have any idea what may have caused this? Is there a directory size limit in PHP or something? I hope they are still there and just unreadable...
Reply With Quote
  #97  
Old 16 Mar 2008, 22:55
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Would it be possible the access rights of the folder have changed and you have no READ and/or LIST permission?
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #98  
Old 16 Mar 2008, 23:10
ChurchMedia's Avatar
ChurchMedia ChurchMedia is offline
 
Join Date: Dec 2002
Real name: Tim Eason
I have a dedicated server and I have full management over it. I discovered about an hour ago that all of my profile pix have been deleted as well. Myself and a server wiz-kid from Seattle are looking into it. He doesn't think we are being hacked. It may have something to do with GD. UG! Either way it's a nightmare and I'm going to pay for daily backups now.

So, your mod is fine (it's great, in fact )!
Reply With Quote
  #99  
Old 17 Mar 2008, 00:50
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Phew (for me)

Anyway I've checked the code and there is no possibility of an accidental deletion.
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #100  
Old 15 May 2008, 03:15
GlitterKill GlitterKill is offline
 
Join Date: Jul 2002
Real name: Gary Mullins
installed on VB 3.7 and working great! Thanks! I have been looking for something like this for a long time!
__________________
Admin for PCApex.com and GameApex.com.
Reply With Quote
  #101  
Old 19 May 2008, 08:18
yahoooh yahoooh is offline
 
Join Date: Oct 2002
how to make it work with vba dynamics script and also vblog and others
i need some hint on this
Reply With Quote
  #102  
Old 19 May 2008, 08:59
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Originally Posted by yahoooh View Post
how to make it work with vba dynamics script and also vblog and others
i need some hint on this
I don't believe there is a simple solution - sounds rather like a major hack, if the standard hooks don't work. Maybe you're lucky with choosing similar hooks and copy & paste the code from the image cache standard hook locations as is ...
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #103  
Old 26 May 2008, 23:18
kether1 kether1 is offline
 
Join Date: Jun 2006
Real name: Kether
Hi Giovanni,

Anyway to edit this to cache images that are from my forum URL? I am thinking of installing the imagehosting modification and would like to be able to cache the images posted in the forum using the [ img ] code so that if a user later deletes his/ her gallery photo, the image would still appear in the thread. Is there a code or something I could edit to change this to capture images from my forum that are linked?

Thanks,
Kether
Reply With Quote
  #104  
Old 27 May 2008, 12:36
y2ksw's Avatar
y2ksw y2ksw is offline
 
Join Date: Aug 2003
Real name: Giovanni
Originally Posted by kether1 View Post
Hi Giovanni,

Anyway to edit this to cache images that are from my forum URL? I am thinking of installing the imagehosting modification and would like to be able to cache the images posted in the forum using the [ img ] code so that if a user later deletes his/ her gallery photo, the image would still appear in the thread. Is there a code or something I could edit to change this to capture images from my forum that are linked?

Thanks,
Kether
you may edit the attached PHP file in order to read also the images from your site, but probably you will run in the problem to cache the images again and again, each time somebody makes a change or replies to a message with a cached image.
__________________
Giovanni
Italian support: http://www.vbulletin.it/
Reply With Quote
  #105  
Old 28 May 2008, 00:04
kether1 kether1 is offline
 
Join Date: Jun 2006
Real name: Kether
Originally Posted by y2ksw View Post
you may edit the attached PHP file in order to read also the images from your site, but probably you will run in the problem to cache the images again and again, each time somebody makes a change or replies to a message with a cached image.
Thanks for the information! Is there a specific piece of code in the PHP file that I should look for to make this change?

Regards,
Kether
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

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


New To Site? Need Help?

All times are GMT. The time now is 20:29.

Layout Options | Width: Wide Color: