View Full Version : Image Cache
y2ksw
08-06-2006, 10:00 PM
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 (https://vborg.vbsupport.ru/showthread.php?t=253309)
This product caches images from external sites to a local board folder (including signatures) located at:
http://www.domain.tld/[forum/]imgcache
Installation
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)
Create an empty index.html file in this folder to avoid file exploring and direct download on some systems.
Copy the y2kswimgcache.php file to your vBulletin board (forum home) directory.
Close your forum temporarily to the public.
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.
Test the product: New thread, reply, edit. If errors occur (or white pages), make sure your imgcache/ folder has the required access rights.
Reopen your forum to the public.
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
The Chief
08-07-2006, 10:10 PM
this looks amazing, good work!!
Eagle Creek
08-08-2006, 01:16 AM
Sounds great!
But isn't this a great increase of your bandwith? I asked my members to user sites like imageshack to upload their pictures.
When I'm going to cache it all, they can just upload it as an attachment. Can't they?
hotma1l
08-08-2006, 02:31 AM
What If i have an upload script for members, So they can upload their images and files, when they upload they get the link, then they will post the new topic, and the images are already on my server,it be uploaded again to the cache image ,,
So is there is away to exclude links for example any images that have been uploaded to http://up.domain.com/uploads/ should be excluded,
if there is an option in the admin control page to exclude links that would be great.
anyway thanks for the great work
y2ksw
08-08-2006, 09:59 AM
Sounds great!
But isn't this a great increase of your bandwith? I asked my members to user sites like imageshack to upload their pictures.
When I'm going to cache it all, they can just upload it as an attachment. Can't they?
It increases the bandwidth quite a lot, and members can make attachments.
However, over the years, we experienced that most forum members don't like attachments, and prefer to insert the pictures in their messages as required. Not much an issue for just one image, but quite some if you have to tell about mathematic, scientific or medical research. And specifically in these areas a missing image source may void the whole discussion.
y2ksw
08-08-2006, 10:04 AM
What If i have an upload script for members, So they can upload their images and files, when they upload they get the link, then they will post the new topic, and the images are already on my server,it be uploaded again to the cache image ,,
So is there is away to exclude links for example any images that have been uploaded to http://up.domain.com/uploads/ should be excluded,
if there is an option in the admin control page to exclude links that would be great.
anyway thanks for the great work
The script is intended to use where other scripts aren't available, or image sources are too slow, as most of the free image hosting sites.
Loading images from the own site has been always the best solution, although it has a cost: bandwidth and web space. ;)
kether1
08-08-2006, 06:06 PM
This looks great! I wonder if it will work with the Lightbox mod? I was thinking of installing that mod and using thumbnails on my forum. Would there be a conflict with 'Image Cache'? I am guessing no, but let me know if you think their might be.
Thanks so much.
Kether
Cole2026
08-09-2006, 01:27 AM
This looks great! I wonder if it will work with the Lightbox mod? I was thinking of installing that mod and using thumbnails on my forum. Would there be a conflict with 'Image Cache'? I am guessing no, but let me know if you think their might be.
Thanks so much.
Kether
It will not.
y2ksw
08-09-2006, 09:09 AM
This looks great! I wonder if it will work with the Lightbox mod? I was thinking of installing that mod and using thumbnails on my forum. Would there be a conflict with 'Image Cache'? I am guessing no, but let me know if you think their might be.
Thanks so much.
Kether
I don't have any experience with the Lightbox mod. However I would assume it would not conflict, since the Image Cache catches the image contents and redirects the URL's to the local server. So even if there is another plugin or modification to elaborate further (like vBulletin does itself, after caching), there should be really no problem.
gamebrink
08-25-2006, 01:22 AM
I love you.
Would you consider adding an option that will rezise the image in the post and link it to the full size image?
y2ksw
08-25-2006, 03:37 PM
I love you.
Would you consider adding an option that will rezise the image in the post and link it to the full size image?
You mean thumbnailing?
I've been thinking about it, actually it isn't that big job, but it's also a question of reputation; just 5 installs mean, it isn't that great plugin and needed only from a few forum holders, of course, the quality-over-quantity-oriented ones ;)
I think if this plugin becomes more widely used, it also would become standard part of vBulletin itself, since it would be only a natural evolution of the actual attachments - dynamically attached items.
It is quite some time people are asking this feature at the official boards and sooner or later it will happen - only a question of time, and as far as I remember, was already working in some of the early beta versions of 3.0.x.
So generally spoken I don't mind to see deeper into the problem but will also wait a little, to see if this pugin becomes more used after the summer holidays :)
ChurchMedia
08-26-2006, 07:15 PM
Could this be made to work in the user's signatures also? I have a lot of members putting userbars (www.userbars.com) in their sig. The problem is, when userbars.com goes down it slows my pages down. I'd love to be able to cache those userbars...
y2ksw
08-27-2006, 12:33 AM
Could this be made to work in the user's signatures also? I have a lot of members putting userbars (www.userbars.com (http://www.userbars.com)) in their sig. The problem is, when userbars.com goes down it slows my pages down. I'd love to be able to cache those userbars...
vBulletin 3.6.0 allows to save the signature picture as long as it is only one. I will think about it ;)
ChurchMedia
08-27-2006, 03:23 AM
vBulletin 3.6.0 allows to save the signature picture as long as it is only one. I will think about it ;)
These are multiple images that would need to be cached. I'm not ready to upgrade to 3.6 until more hacks have been ported.
I'm willing to pay for the plug-in. :cool:
y2ksw
08-27-2006, 02:04 PM
These are multiple images that would need to be cached. I'm not ready to upgrade to 3.6 until more hacks have been ported.
I'm willing to pay for the plug-in. :cool:
I've added IMG caching of signatures.
Although this product/plugin is free, a voluntary payment (donation) for new feature requests would greatly help to add them in a reasonable time. For this reason we have added a donation button inside readme.htm for a symbolic contribution of EUR 5.00.
ChurchMedia
08-27-2006, 03:21 PM
Thanks! I really appreciate it. Great hack! :)
Donation sent
y2ksw
08-27-2006, 04:46 PM
Thanks! I really appreciate it. Great hack! :)
Donation sent
Thank you, you're welcome! :)
grazianno
09-12-2006, 12:04 PM
thx y2ksw for this mod,
can you tell me plz where images are hosted ? because i dont see any images in imgcache
y2ksw
09-12-2006, 12:40 PM
If the images cannot be stored in the imgcache folder, the links to the original source remain intact, thus are hosted as if the plugin wasn't installed.
Please make sure to give at least the read/write rights to the imgcache folder, or storage will fail.
adwade
09-23-2006, 06:29 PM
Test the product: New thread, reply, edit. If errors occur (or white pages), make sure your imgcache/ folder has the required access rights.
Installed and everything seemed to go just fine. Did the above test and all seems well.
QUESTION: Should my imgcache directory I created begin to contain copies of images now? So far, I've not seen anything in there except the empty index.html file I created per the instructions.
adwade
09-23-2006, 06:33 PM
One other question, I run vBadvanced's CMPS. Is there a way to get this to cache what pics show up on that page as well?
y2ksw
09-23-2006, 08:56 PM
Installed and everything seemed to go just fine. Did the above test and all seems well.
QUESTION: Should my imgcache directory I created begin to contain copies of images now? So far, I've not seen anything in there except the empty index.html file I created per the instructions.
The folder should hold images if you have pasted images from other sites in your messages. For example copy this forum logo into your edit box and save. It should cache the smilie. If it doesnt, it may be your imgcache folder has not the rights to write.
y2ksw
09-23-2006, 08:57 PM
One other question, I run vBadvanced's CMPS. Is there a way to get this to cache what pics show up on that page as well?
I don't know, but I suppose it is. However I have no time to look into that too ;)
adwade
09-23-2006, 09:04 PM
The folder should hold images if you have pasted images from other sites in your messages. For example copy this forum logo's location into your edit box and save. It should cache the smilie. If it doesnt, it may be your imgcache folder has not the rights to write.
Now I understand what you're saying. Yes, I copied the location and posted it in a test msg and, wha-la instantly a 1.imgcache file was created in the imgcache directory. Thanxx!
adwade
10-24-2006, 12:20 PM
Out of curiosity, is there any way to view the image cache file to see what all it contains?
y2ksw
10-24-2006, 08:14 PM
Maybe not online, but by downloading and using an image (pre)viewer I'm pretty sure you may see the file contents. ;)
adwade
10-25-2006, 03:18 AM
Yep, you are exactly right.:classic: I D/L'd the 1.imgcache, 2.imgcache, etc files to my desktop and used Quick View Plus to peek at 'em. Neat, Thanxx!
JohnBee
10-27-2006, 08:20 PM
Strange phenomenon here.
When users add inline images the cache works however when they click on the image they cannot view the full size image instead they are offered to download a .cache file..
Any ideas how to fx this, its a little confusing?
y2ksw
10-27-2006, 09:12 PM
Basically it is possible to change the script to save the cached images with another name. Still there is a basic problem I didn't solve: The cache takes any image format and saves it as-is from the source site.
JohnBee
10-27-2006, 10:18 PM
Basically it is possible to change the script to save the cached images with another name. Still there is a basic problem I didn't solve: The cache takes any image format and saves it as-is from the source site.
It is a great hack I will give it this.
If you could arrange for it to maintain standard image format filenames it would really help integrate it with other image functions within vBulletin. I will uninstall it for the time being, only because my members are confused about this. But I do hope you can change this because this is a very useful and helpful approach to an age old problem.
maaref
10-29-2006, 08:27 AM
Great mod you made y2ksw
I like it.
some admins have a limited space to store images in their site, I have some suggestions for future update (if possible)...
add options in ACP to enable/diable:
- signature storage
- storage based on usergroups, users names... this will be excellent for proffesional forums/images describe process by certain members.
- store images in different server/site...because of space limitation. the new location could be owned by same admin.
genius mod, thanks again.
y2ksw
10-29-2006, 03:53 PM
Great mod you made y2ksw
I like it.
some admins have a limited space to store images in their site, I have some suggestions for future update (if possible)...
add options in ACP to enable/diable:
- signature storage
- storage based on usergroups, users names... this will be excellent for proffesional forums/images describe process by certain members.
- store images in different server/site...because of space limitation. the new location could be owned by same admin.
genius mod, thanks again.
The storage based on forums and/or usergroups has been requested already, but I'm in a sort of stall right now (too many jobs) and cannot concentrate much on adding features.
Storing mages on another server may create many authentication problems, and in the end, if that server is down, the problem of unlinked images reappears again, reason for which this plugin has actually been created :p
maaref
10-30-2006, 07:32 AM
Thank for the effoer,
sounds a nice mod...
caching external image..
vb3.6.4 has been released....
its supported by vb 3.6.4 ?
any new feature is coming or any update ?
y2ksw
12-27-2006, 12:40 PM
Sure, it's fully compatible with vBulletin 3.6.4
adhari_com
01-31-2007, 04:53 PM
then shouldn't it be moved into 3.6.4?
y2ksw
01-31-2007, 07:18 PM
then shouldn't it be moved into 3.6.4?
Yeah, maybe :p
Still, there are many users of v. 3.5 which can't upgrade because of their server/PHP/MySQL limitations, and this forum is much less crowded than anywhere else.
Let's say, when I assume v. 3.5 is definitively dead, I will ask to move the thread to the 3.6 forums :)
KingPin6
02-19-2007, 07:58 PM
thank you for an awesome mod, is there anywhere I can specify to ignore sig images? or even better, images from the forums domain? we have a default sig for each user that needs to stay updated with stats from game server, stats are based from same domain. being able to turn off cache for same domain would be awesome, thank you.
y2ksw
02-19-2007, 10:16 PM
You may disable the specific plugin for signatures. When diabled, signatures are not considered :)
KingPin6
02-20-2007, 12:56 AM
thank you.
RealitYYY
03-28-2007, 08:15 AM
This is great though is it able to be for specific forums and pm messages and not the entire site...
Xplorer4x4
04-01-2007, 08:07 PM
This is great though is it able to be for specific forums and pm messages and not the entire site...
Not tested but try putting<if condition="n_array($GLOBALS[forumid], array(X,Y,Z))">as the first line of every plug in for this hack. Then put </if> as the last line if each plug in for this hack.
Replace XYZ with the forums ids of the forums you want it to cache in.
y2ksw
04-02-2007, 10:17 AM
<if condition="in_array($GLOBALS[forumid], array(X,Y,Z))">
may work for templates only (n_array does not work for sure :p )
maxicep
04-02-2007, 12:35 PM
<if condition="in_array($GLOBALS[forumid], array(X,Y,Z))">
may work for templates only (n_array does not work for sure :p )
i do it what you write, bu take an error when posting and editing on forum than i uninstalled .:(
y2ksw
04-02-2007, 05:48 PM
The plugin has been written for entire sites, not for selections of forums and subforums. Unless I will release a version which allows selecting forums, I do not suggest to make a change to templates. I corrected a typo, in a hypothetically working template modification. ;)
home9000
04-13-2007, 03:44 PM
very nice product
let assume that I disable the product after one month what is the impact ?
I will lose all images , is this right ?
y2ksw
04-14-2007, 08:26 AM
No, the images you have stored on your server remain. After uninstalling/disabling, newly pasted images will not be stored to your server any more. That's all :)
home9000
04-17-2007, 07:39 AM
Is it possible to print logo over the images that store in the site ?
like this
https://vborg.vbsupport.ru/showthread.php?t=112829&highlight=watermark
or this
https://vborg.vbsupport.ru/showthread.php?t=141883&highlight=watermark
y2ksw
04-17-2007, 11:41 AM
Not yet. It has been asked before and when I got time to review this plugin, I may add this feature.
home9000
04-29-2007, 07:08 AM
Thanks y2ksw
one more question, The hack will be work for the new post . I want to include the old post is there any way like Update Counters
y2ksw
04-29-2007, 11:36 PM
Not yet, sorry. Also this feature was asked in the past, but I'm unable to concentrate on addons and changes, since busy in real life ;)
If you know a little PHP you may create a new cron-job and parse the messages one by one (or a small number of messages) at each interval. It is not a huge deal with an additional table where you keep trace of the messages you already parsed, or an additional field in the post table (which I discourage).
The 'update counters' isn't a great idea on large boards, because you need to take care about script timeouts. When you time out, you have to reload the page manually. On certain systems, the timeout can be disabled for cron-jobs, and most of all, they run in the background without the need of a human clicking for hours on a stupid button :p
home9000
05-01-2007, 07:59 PM
Thanks y2ksw
Is it possible to let each month picture have a different folder in this way the number of files not going to effect the performance and it's easy to delete the old files.
my second suggestions and it's good for next release to keep in database the old picture url and you can just replace the url if the picture missing only so the bandwidth not effect in this way
home9000
05-19-2007, 04:02 PM
I have problem right now to add any new post because its take time .Maby the problem because all image save in one folder
I have to stop the product right now and I hope we can get fix
ChurchMedia
08-18-2007, 09:59 PM
Any chance on a port to 3.6.8? It stopped working for me a couple of revs back.
y2ksw
08-19-2007, 07:56 AM
Any chance on a port to 3.6.8? It stopped working for me a couple of revs back.
I check what's going on ... probably a hook location which has been changed ;)
Thanks for feedback
ChurchMedia
08-19-2007, 01:50 PM
I check what's going on ... probably a hook location which has been changed ;)
Thanks for feedback
Actually it was because my imgcache folder wasn't chmod to 777. My bad. Sorry!
y2ksw
08-20-2007, 02:48 PM
No problem ... there was also an issue on IE7 which may not allow to show correctly *.imgcache images. New files are named *.png now and everything works ;)
KingPin6
08-20-2007, 08:02 PM
hello y2ksw thank you for the update, it was always a bit slow with this mod when making posts with pictures but now after this update I cant make posts at all if it contain a few pictures, I see the pictures in the imgcache folder but the post never gets made, I just waited almost 5 minutes and then just canceled, disabled addon and retried, the post was made in a few seconds. any tips would be much appreciated.
y2ksw
08-21-2007, 08:46 PM
hello y2ksw thank you for the update, it was always a bit slow with this mod when making posts with pictures but now after this update I cant make posts at all if it contain a few pictures, I see the pictures in the imgcache folder but the post never gets made, I just waited almost 5 minutes and then just canceled, disabled addon and retried, the post was made in a few seconds. any tips would be much appreciated.
Strange ... anyway 17 seconds for a message is long. I'll upload the previous version (1.0.2.0) to allow reverting.
The changes I've made should actually use much less memory, specifically when there are more images in a message, at a single time.
KingPin6
08-22-2007, 02:53 PM
17 was a typo ;) which I fixed before your post but you read it already :) thank you, I will debug my setup further and will reply back with anything I come up with.
Lethe
08-25-2007, 07:06 PM
actually nice mod..thx..
i used it for 1 week but i just have to much images on my users posts so i uninstalled it.. in one week i got nearly 100 mb in the imgcache folder. i cant delete them couse all links are automaticly rewritten to the imgcache folder..
the question is ; is there a way to rewrite them back ?
y2ksw
08-26-2007, 09:00 AM
actually nice mod..thx..
i used it for 1 week but i just have to much images on my users posts so i uninstalled it.. in one week i got nearly 100 mb in the imgcache folder. i cant delete them couse all links are automaticly rewritten to the imgcache folder..
the question is ; is there a way to rewrite them back ?
Sorry, there is no way, since the original URL is not stored anywhere.
thanx 4 the hack
some user have issue with it
when i put manny image in my post and add it .. it will take long time to show
and some time it give me server Busy ?
HTTP 408/409 Server Busy
how can i fix it ?
thanx agin my frined
vBulletin Version 3.6.8
y2ksw
10-06-2007, 10:53 PM
Every image is downloaded form the source as-is, and thus may take quite some time to download. The message will not show up before all images are downloaded.
If you host on a fast server, this should not be an issue, but on shared systems it may be a problem.
hilfe-forum
10-13-2007, 04:53 PM
Hmm dont work wen Pic URL is not hard-Postet....
y2ksw
10-14-2007, 05:00 AM
Well, sure, an image link is always an URL and thus handled just as that.
yahoooh
10-14-2007, 07:43 AM
there is an error should be fixed:
i have gallery for images and also hosting images service
when a member use images already in my gallery on on my server it will be also copied and go to imgcache and i think this is not needed so
how to exclude images that already present on my site folders ?
hilfe-forum
10-14-2007, 07:11 PM
Well, sure, an image link is always an URL and thus handled just as that.
no change to work with revite URL?s?
in my Board a plugin revite this url: "www.abc.de" to this "pic.abc.de/fg.jpg"
So in post i see the picture but your plugin only see www.abc.de?... :(
booktoweb
10-15-2007, 03:32 AM
its not work with me in 3.6.8
yahoooh
10-16-2007, 05:55 AM
its not work with me in 3.6.8
it works with me
booktoweb
10-21-2007, 12:56 AM
i dont know why its not works with me
i am using it from version 3.0.8 without any problem
========
open directory imgcache and make its CHMOD 777
upload y2kswimgcache.php
Install the product (product-y2kswimagecache.xml)
========
used old version and latest version
y2ksw
10-21-2007, 09:33 PM
Do you have any other hacks installed? If yes, which?
booktoweb
10-22-2007, 07:30 PM
i installed new test forum and try hack
but its not works
yahoooh
10-30-2007, 06:31 PM
still i need : to not cache images that already in mu server
any update
y2ksw
10-30-2007, 07:20 PM
still i need : to not cache images that already in mu server
any update
I think that is not easy to perform. However I'll look into it for the next release.
bkaul
11-09-2007, 07:33 PM
its not work with me in 3.6.8
It has been working in 3.6.8 for me, but upon patching to PL2, it now generates a PHP Access Violation whenever a new post using [img] code is submitted.
y2ksw
11-09-2007, 07:52 PM
I have patched and tried right now, and the is no problem at all. However I just replaced the files, not doing the full upgrade.
ChurchMedia
11-09-2007, 08:19 PM
It has been working in 3.6.8 for me, but upon patching to PL2, it now generates a PHP Access Violation whenever a new post using [img] code is submitted.
I'm patched -- no problems here.
bkaul
11-13-2007, 09:48 PM
I'm patched -- no problems here.
Hmm ... problem started on the same day that I patched it. Odd. No disk space or database problems... will have to poke around a bit and see what I can figure out, I guess.
bkaul
11-13-2007, 10:18 PM
No idea what the cause was, but uninstalling & reinstalling the product fixed it...
BadgerDog
11-14-2007, 03:38 PM
Just a clarification please.... :confused:
The instructions say:
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.
So, if I install and try this, but it doesn't work or I for whatever other reason I want to un-install it and return my system to its current state, does this mean I can't?
Thanks... :)
Regards,
Badger
y2ksw
11-15-2007, 04:41 PM
Just a clarification please.... :confused:
The instructions say:
So, if I install and try this, but it doesn't work or I for whatever other reason I want to un-install it and return my system to its current state, does this mean I can't?
Thanks... :)
Regards,
Badger
It means if you uncomment the uninstallation code (remove starting /* and ending */) from the product uninstallation, it will uninstall completely.
It also means (with removed comments), if you install it later again, the numeric counter will restart from 1 and thus all previously cached images will be gradually overwritten by newly cached images.
If you leave the table in place (not removing comments), you can reinstall at any without this problem. And for this reason it is commented out.
BadgerDog
11-15-2007, 04:58 PM
It means if you uncomment the uninstallation code (remove starting /* and ending */) from the product uninstallation, it will uninstall completely.
It also means (with removed comments), if you install it later again, the numeric counter will restart from 1 and thus all previously cached images will be gradually overwritten by newly cached images.
If you leave the table in place (not removing comments), you can reinstall at any without this problem. And for this reason it is commented out.
Understood.... :up:
Thank you ... :)
Regards,
Badger
Triky
11-15-2007, 08:28 PM
Hi y2ksw, I like this mod. I want to support it becouse it's a really a nice idea, however I think I will not install it on my web site, becouse right now I have a standard hosting plan with not so much bandwidth and web space. :p
By the way, thank you for this modification, I've installed it.. maybe in a future it could be helpfull. :)
y2ksw
11-15-2007, 11:28 PM
Thanks, it's always nice to hear from happy users :)
Mazinger
02-15-2008, 02:12 PM
Didn't work with me... the images are still have their original url.
y2ksw
02-15-2008, 02:51 PM
Does your imagecache folder have modify (chmod 777) permissions? Without it surely won't assign a local URL.
Mazinger
02-15-2008, 03:13 PM
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.
Mazinger
02-18-2008, 10:46 AM
Any other clues?
y2ksw
02-18-2008, 02:28 PM
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 :)
Any other clues?
Sorry, no other ideas ...
Mazinger
02-18-2008, 07:12 PM
Is there any other php/server requirements/conditionals that this hack wouldn't work with?
y2ksw
02-18-2008, 09:55 PM
Maybe if fopen() would not work. But at this point you would not be able to save attachments on your server as well.
Mazinger
02-27-2008, 07:08 AM
I just checked, and fopen() is off in the php info. Is there any way to enable it via .htaccess?
y2ksw
02-27-2008, 01:37 PM
Not as far as I know, sorry.
ChurchMedia
03-16-2008, 05:01 PM
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...
y2ksw
03-16-2008, 09:55 PM
Would it be possible the access rights of the folder have changed and you have no READ and/or LIST permission?
ChurchMedia
03-16-2008, 10:10 PM
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 :))!
y2ksw
03-16-2008, 11:50 PM
Phew (for me) :)
Anyway I've checked the code and there is no possibility of an accidental deletion.
GlitterKill
05-15-2008, 02:15 AM
installed on VB 3.7 and working great! Thanks! I have been looking for something like this for a long time!
yahoooh
05-19-2008, 07:18 AM
how to make it work with vba dynamics script and also vblog and others
i need some hint on this
y2ksw
05-19-2008, 07:59 AM
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 ... :confused:
kether1
05-26-2008, 10:18 PM
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
y2ksw
05-27-2008, 11:36 AM
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.
kether1
05-27-2008, 11:04 PM
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! :up: Is there a specific piece of code in the PHP file that I should look for to make this change?
Regards,
Kether
y2ksw
05-28-2008, 06:42 AM
Thanks for the information! :up: Is there a specific piece of code in the PHP file that I should look for to make this change?
Regards,
Kether
Around line 55:
/*
// Don't change already cached files ---------------------------------------
for($i = 0; $i < $n; $i++)
{
if(strpos($files[$i]['url'], $forum_home . 'imgcache/') !== FALSE)
{
$files[$i]['url'] = '';
}
}
*/
:)
y2ksw
05-28-2008, 06:46 AM
Anyway I think you don't have to make this change because it would cache all files on your site, but the ones you already have in the imgcache folder ;)
kether1
05-28-2008, 10:30 PM
Hi Giovanni,
Thanks for all of your replies. I am not sure I understand what I am supposed to change in the code quoted in post 106. Do I simply set it to TRUE to capture all linked images? Sorry for being so thick about this.
Anyway I think you don't have to make this change because it would cache all files on your site, but the ones you already have in the imgcache folder
Also, I am not sure if you are telling me that making this change is a bad idea or if you mean something else.
Thanks for your help,
Kether
y2ksw
05-29-2008, 10:25 AM
Well I d'dn't check yet how album images are handled, when they are referred inside a post. I would assume they are simple IMG tags and thus the images should already be cached ... can't you make a test please? :) If caching works, the link should read [forumhome]/imgcache/[id].png
Regards,
Giovanni
kether1
05-29-2008, 11:56 PM
Well I d'dn't check yet how album images are handled, when they are referred inside a post. I would assume they are simple IMG tags and thus the images should already be cached ... can't you make a test please? :) If caching works, the link should read [forumhome]/imgcache/[id].png
Regards,
Giovanni
Oh, I have tested it, Giovanni. It doesn't make a cache of the image. The link will simple be: http://www.mysite.com/forum/imagehosting/34827686d769c2.gif
It doesn't get the /imgcache/[id].png like everything linked in from off of my URL. I *think* this is because my forum's URL is included in the link and your modification doesn't cache images from the URL that it is working within. That is why I wanted to know how to change the code in the PHP file to make it capture images that are put into post from my own forum URL.
I really appreciate you help with this. I love this modification.
Regards,
Kether
y2ksw
05-30-2008, 06:13 AM
At this point try to comment out the code at line 55 and see if anything changes.
kether1
05-30-2008, 12:07 PM
At this point try to comment out the code at line 55 and see if anything changes.
I tried it, but it did not change. Sorry I missed the
/* and */ in the code in post 106 or I would have tested it earlier. The y2kswimgcache.php file still behaves the same way with regards to the imagehosting images and other images that are on my forum's URL. Perhaps there is another place in the code I need to edit?
Thanks again!
kether
y2ksw
05-30-2008, 02:30 PM
Maybe these images are virtual or cannot be accessed. The procedures silently fail when a file is not readable for any reason.
kether1
05-31-2008, 01:27 AM
Oh, no. Well, I appreciate the time you spent trying to help me. I really appreciate it and your modification. If I can discover a way to make it work, I will PM you and let you know. If you think of something else for me to try, I will be happy to give it a go.
I am just surprised that none of the images from my forum URL are cached after making that code change. I expected some of them to at least cache.
Thanks again,
Kether
booktoweb
06-03-2008, 07:26 AM
after edit to
allow_url_fopen = On
this hack worked well
aisais
07-13-2008, 01:15 AM
Thank you for sharing this mod.
Is it compatible with 3.7.2 ?
y2ksw
07-13-2008, 10:20 AM
Yes, it is running flawlessly on my servers including the versions 3.6.x and 3.7.x :)
aisais
07-14-2008, 04:52 AM
Yes, it is running flawlessly on my servers including the versions 3.6.x and 3.7.x :)
Great. :up: Thank you y2ksw.
salahunreal
08-12-2008, 12:36 PM
Tested on new thread, reply edit with 3.6.8 forum and worked properly.
As other stated before me, would be good idea if there an option to exclude some directories since some forums has their own uploading script.
I agree this option should be included in the 3.7 forums. this is a must have in my opinion.
Thanks for the great work
y2ksw
08-12-2008, 10:13 PM
hmmm ... seems as if I will have to make this and some other changes and upgrades soon ... ;)
Mazinger
08-22-2008, 10:59 PM
What are system requirements?
y2ksw
08-23-2008, 07:35 AM
What are system requirements?
The access to external files through the file_get_contents() function must be granted, thus fopen() on URL's must work.
Mazinger
08-23-2008, 03:03 PM
Thanks!
Working now with safe mode off.
snotek
09-22-2008, 01:48 PM
It would seem as though we have a need for this, but some updates and new features would be nice - so long as vB 3.7.x doesn't allow this already. We're not going to install this until we update though. Soon.
We run an information based site and notable threads get placed in our archives. Currently the mods have to manually edit the source of every external image and upload it as an attachment before moving the thread(s) to the archives.
This mod would make this work effort obsolete.
Questions:
If two people link to the same offsite image but in different threads, does this mod track that and link to the same image? Or does it simply cache it again.
Can this mod be made so that instead of caching the images it simply makes them an "attachment" as the user that posted the thread?
Are any future updates planned for this mod or is it final as-is?
Are there options that allow us to determine which images get cached and which don't?
Is there a way to clean up the cache over time for images that are in threads that we are not archiving and are no longer relevant?
y2ksw
09-22-2008, 03:44 PM
It would seem as though we have a need for this, but some updates and new features would be nice - so long as vB 3.7.x doesn't allow this already. We're not going to install this until we update though. Soon.
We run an information based site and notable threads get placed in our archives. Currently the mods have to manually edit the source of every external image and upload it as an attachment before moving the thread(s) to the archives.
This mod would make this work effort obsolete.
Questions:
If two people link to the same offsite image but in different threads, does this mod track that and link to the same image? Or does it simply cache it again.
Can this mod be made so that instead of caching the images it simply makes them an "attachment" as the user that posted the thread?
Are any future updates planned for this mod or is it final as-is?
Are there options that allow us to determine which images get cached and which don't?
Is there a way to clean up the cache over time for images that are in threads that we are not archiving and are no longer relevant?
It works on my 3.7.x forums as-is perfectly well.
If two people link to the same offsite image but in different threads, does this mod track that and link to the same image? Or does it simply cache it again? The images are cached again. However, if a user copies an already cached image, it will just copy the reference.
Can this mod be made so that instead of caching the images it simply makes them an "attachment" as the user that posted the thread? This would create a cached image of any copy and thus raise the memory amount sensibly.
Are any future updates planned for this mod or is it final as-is? There is an unpublished modification which retrieves also images from imageshack and many other services, together with preview icons and expanded images. However it is rather complicated to use and maintain. So at the moment it remains as-is.
Are there options that allow us to determine which images get cached and which don't? None yet.
Is there a way to clean up the cache over time for images that are in threads that we are not archiving and are no longer relevant? You may look at the FTP time stamp of the files and delete those which are probably out of date.
Shamil.
10-03-2008, 10:13 AM
Would you be able to add a watermarking option to this mod?
y2ksw
10-03-2008, 11:41 AM
Would you be able to add a watermarking option to this mod?
Yes, sure (GD only). Please note, that adding a watermark could require quite some resources, since the image(s) must be loaded into memory. On the other hand, this would allow also to resize and save in a common file format.
mac-warez
10-07-2008, 11:06 AM
This works good on vbulletin 3.73 i have had it running for about a month with no problems
Super Jinni
10-25-2008, 05:08 PM
thanks for the great mod Giovanni
I've a question?
is there anyway to change the images extension from the png to the original image extension (gif, jpg, etc..)? or even to another extension instead of png extension?
I want this cause I've most of users use IE 5 and 6 which they have issues with pngs transparency.
hope to here soon from you..
thanks
:)
y2ksw
10-25-2008, 06:22 PM
thanks for the great mod Giovanni
I've a question?
is there anyway to change the images extension from the png to the original image extension (gif, jpg, etc..)? or even to another extension instead of png extension?
I want this cause I've most of users use IE 5 and 6 which they have issues with pngs transparency.
hope to here soon from you..
thanks
:)
You may try to change the png extension at line 103 (y2kswimgcache.php) to something else. The change will apply to new images only.
The images are not transformed though, thus they may or may not work either way. The png extension was given to avoid XSS issues by Internet Explorer 6/7, but in fact the extension does not dictate in any way how images are shown.
AnabolicResourc
11-18-2008, 08:15 PM
Clicks Installed !!
Correct me if i'm wrong.
Saving a copy to the imgcache is only working with new posts ?
Old posts needs pressing the edit button and saving again ?
Is there a way to make that easier ? So every old post with linked pictures are stored in imgcache ?
A watermark option would be so very nice !!
On my gallery and vB attachments i already have it, now i only need it on linked images and allbums pics.
y2ksw
11-18-2008, 11:09 PM
Clicks Installed !!
Correct me if i'm wrong.
Saving a copy to the imgcache is only working with new posts ?
Old posts needs pressing the edit button and saving again ?
Is there a way to make that easier ? So every old post with linked pictures are stored in imgcache ?
A watermark option would be so very nice !!
On my gallery and vB attachments i already have it, now i only need it on linked images and allbums pics.
I have somewhere also a procedure which imports old images from amost all kind of storages (incl. 3 different imageshack versions) but needs to be assisted a little and uses quite some resources. Also I'm lacking of time to supervise or explain it. It's only worth it to use if you have a dedicated server and may change PHP settings (timeout, no safe mode, memory usage). On shared servers it would have so many caveats that it probably will cause more problems than it solves.
But for a good start you could use this plugin :)
And oh well with vbulletin 3.5 there were no albums and so, thus really will save only pasted images of new posts...
Mazinger
12-04-2008, 04:44 PM
Possible to cache images on external server?
y2ksw
12-05-2008, 05:00 PM
Possible to cache images on external server?
Nope. The idea was to import the images to the local server in order to keep images permanently in reach.
If they would be stored on an external server, the problem of missing images would reappear each time the external server is down. ;)
Mazinger
12-06-2008, 06:09 AM
Actually, i wanted to put images on another website (on the same server).
Something I think Yahoo! and Google follows for uploading their content images.
Yahoo!, for example have the website yimg.com which contains nearly most of the images displayed on Yahoo! and that fastens the loading speed of the parent Yahoo!, site I belive.
Having the images on the same website will consider them content images, and will slow forum.
e7saas
03-05-2009, 11:35 AM
good work
y2ksw
03-05-2009, 01:19 PM
You're welcome :)
yahoooh
06-13-2009, 04:53 AM
is there away to make it work with :
vblog
vba dynamic
y2ksw
06-13-2009, 10:40 AM
is there away to make it work with :
vblog
vba dynamic
I'm sorry, I currently don't have enough time to dedicate.
Bill from Cleve
06-15-2009, 01:10 AM
Just found this hack thanks to Gasper. Are you going to update it to fix the bugs? This hack is what I am looking for, but has many issues that seem can be fixed to make it perfect.
Bill from Cleve
06-15-2009, 02:13 AM
Sorry, forgot to add this, can you make it to grandfather in all the older posts before installation?
y2ksw
06-15-2009, 08:33 AM
Sorry, I'm in a kind of lack of time and can't dedicate on this hack in order to make it better.
In my archives I have an application which pulls in old images from a wide variety of services (e.g. ImageShack), which I'm willing to supply, but still I can't give support on that, either. :)
bahattab
08-17-2009, 08:36 PM
hi
is there any new ver. for 3.8.x
thanks
regards
Bill from Cleve
09-01-2009, 02:37 PM
hi
is there any new ver. for 3.8.x
thanks
regards
worked great on my 3.8.3.
rubke
09-01-2009, 06:33 PM
Sorry, I'm in a kind of lack of time and can't dedicate on this hack in order to make it better.
In my archives I have an application which pulls in old images from a wide variety of services (e.g. ImageShack), which I'm willing to supply, but still I can't give support on that, either. :)
Is this a script to check the old postings and store the image ?
where can i find it ? no support needed ;)
thanks for this mod !
mhackl
10-14-2009, 02:38 AM
Three questions:
1. Does this cross any lines as far as copyrights are concerned. Since you are essentially making a copy of the image and redistributing it?
2. Is the original link no longer available for the user to reference?
3. Does this only cache remote (off domain) images? If not, is it possible to do that? Answered
Bill from Cleve
11-23-2009, 07:12 PM
Is there a way I can make it NOT cache images in the .PNG format? The problem is, it caches them as .PNG's, but they are actually JPG's and GIF's. This causes watermarking apps to fail because they don't understand the format.
I have tried pretty much every single option for watermarking including the .HTACCESS, but non work with this option enabled. I really love the image cache and do not want to disable it.
Is there any easy way to convert the PNG's back to the original formats without killing anything?
sarangan
11-27-2009, 06:45 AM
Your plugin is very good, i am using on my very large forum. But the problem is i have about 120000 images in the imgcache folder. Because of too much images in a single folder it crashes the server harddisk to get the images and load.
Now the suggestion: It will be good if your script can automatically create new folders for everymonth like when we are in november 2009 then folder name have to be /imgcache/112009/, for december 2009 /imgcache/122009/ etc.
If you can modify the script like this, i am sure your plugin will be the best for ever.
Thank you. :)
ThomasR
02-09-2010, 07:36 AM
No plans of releasing this plugin for vb 4? I'm looking for such plugin and as the targeted forum use tons of images, like Sarangan, a new folder organization would be welcome :)
Focus2
04-14-2010, 12:09 PM
Your plugin is very good, i am using on my very large forum. But the problem is i have about 120000 images in the imgcache folder. Because of too much images in a single folder it crashes the server harddisk to get the images and load.
Now the suggestion: It will be good if your script can automatically create new folders for everymonth like when we are in november 2009 then folder name have to be /imgcache/112009/, for december 2009 /imgcache/122009/ etc.
If you can modify the script like this, i am sure your plugin will be the best for ever.
Thank you. :)
Just change this:
// Create filename
$f = 'imgcache/' . sprintf('%d', $id) . '.png';
To this:
// Create filename
$kd = "imgcache/" . date("m_Y");
if (!is_dir($kd)){
mkdir($kd , 0777);
$filename = $kd . '/index.html';
$Content = "Restricted Access\r\n";
$handle = fopen($filename, 'x+');
fwrite($handle, $Content);
fclose($handle);
}
$f = $kd . '/' . sprintf('%d', $id) . '.png';
No plans of releasing this plugin for vb 4? I'm looking for such plugin and as the targeted forum use tons of images, like Sarangan, a new folder organization would be welcome :)
Works on vb 4.0.1
Focus2
04-14-2010, 12:24 PM
Is there a way I can make it NOT cache images in the .PNG format? The problem is, it caches them as .PNG's, but they are actually JPG's and GIF's. This causes watermarking apps to fail because they don't understand the format.
I have tried pretty much every single option for watermarking including the .HTACCESS, but non work with this option enabled. I really love the image cache and do not want to disable it.
Is there any easy way to convert the PNG's back to the original formats without killing anything?
Further edit of file will keep the original extension:
// Create filename
$ext = end(explode('.', ($files[$i]['url'])));
$kd = "imgcache/" . date("m_Y");
if (!is_dir($kd)){
mkdir($kd , 0777);
$filename = $kd . '/index.html';
$Content = "Restricted Access\r\n";
$handle = fopen($filename, 'x+');
fwrite($handle, $Content);
fclose($handle);
}
$f = $kd . '/' . sprintf('%d', $id) . '.' . $ext;
ThomasR
04-14-2010, 12:40 PM
Focus2: thanks a lot for your edits!!
rubke
04-15-2010, 06:58 AM
feature request(s):
- exclude some (sub)forums from caching.
- a scan and remove of unused images
- a scan and update of images
home9000
11-05-2010, 04:58 AM
Is there a way I can make it NOT cache images in the .PNG format? The problem is, it caches them as .PNG's, but they are actually JPG's and GIF's. This causes watermarking apps to fail because they don't understand the format.
I have tried pretty much every single option for watermarking including the .HTACCESS, but non work with this option enabled. I really love the image cache and do not want to disable it.
Is there any easy way to convert the PNG's back to the original formats without killing anything?
What is the watermarking apps that you use
Manoel J?nior
11-06-2010, 03:36 PM
Please,
Watermark!!!
y2ksw
11-07-2010, 04:10 PM
For all users who have asked for an equivalent of this product for vBulletin 4, here it is (https://vborg.vbsupport.ru/showthread.php?t=253309).
Please try and enjoy :)
Manoel J?nior
11-07-2010, 04:45 PM
@y2ksw:
I have vB 3.6.8 wor for me!!! But, you can implement watermark this version?
y2ksw
11-08-2010, 08:22 AM
@y2ksw:
I have vB 3.6.8 wor for me!!! But, you can implement watermark this version?
I suggest to download the images, watermark and upload them back.
Watermarking is beyond the features of image caching :)
Manoel J?nior
11-08-2010, 10:13 PM
I suggest to download the images, watermark and upload them back.
Watermarking is beyond the features of image caching :)
Thanks, for feedback!
home9000
11-14-2010, 04:40 PM
Is it possible to put the userId or member name part of the file name of the image
y2ksw
11-15-2010, 07:09 AM
Is it possible to put the userId or member name part of the file name of the image
I don't believe so ... in theory yes, but it would add more problems than it solves, since images (links) could be copied and then they would not match the users.
home9000
11-15-2010, 03:29 PM
I don't believe so ... in theory yes, but it would add more problems than it solves, since images (links) could be copied and then they would not match the users.
Yes but I can ignore any link inside the domain so if any one use the image then the original member id will be the same
If you can help I will be appreciated
Baitona
03-18-2011, 03:35 PM
script working 100%
however, i have a little question,
if there was an artilce in my forum, which contanis images
all images are hyperlinked to external sites/threads
when the image is imported it will still have the url after the import...
my question is there any chance to strip the forign url, in the thread?
regards
Baitona
03-19-2011, 09:13 AM
is it also possible to import the images to other domain?
y2ksw
03-19-2011, 10:16 AM
script working 100%
however, i have a little question,
if there was an artilce in my forum, which contanis images
all images are hyperlinked to external sites/threads
when the image is imported it will still have the url after the import...
my question is there any chance to strip the forign url, in the thread?
regards
"Wrapping" URL's are not removed yet and maybe never will.
y2ksw
03-19-2011, 10:21 AM
is it also possible to import the images to other domain?
Short answer: no :)
You would like to store the images to a media server which would need a lot of more operations. However, if you have Linux, you can use the fsftp file system in order to move imported files into another server, or a symbolic link to move it on the same server to another domain. Together with the Forum URL Replacement option, you may achieve then the desired effect. This applies however only to the newer version, here: https://vborg.vbsupport.ru/showthread.php?t=253309
Manoel J?nior
07-18-2011, 02:53 PM
My bro',
Please this version update:
- update all equal to Import External Image (vb4)
- a scan and remove of unused images
- a scan and update of images
- Watermark
- Integrate automatically https://vborg.vbsupport.ru/external/2011/07/5.gif with iMG Cache
Is it possible?
Congratulations, you're a great developer.
y2ksw
07-18-2011, 03:38 PM
You may watermark your pictures with external tools (e.g. download - watermark - upload). I will not add this feature for copyright reasons.
All the other requests may be possible, I'll think about it :)
Manoel J?nior
07-18-2011, 04:01 PM
You may watermark your pictures with external tools (e.g. download - watermark - upload). I will not add this feature for copyright reasons.
All the other requests may be possible, I'll think about it :)
Again, thank you for all the help. Many people still have version 3.8, an update would be very good this product to these people.
Thanks again.
Manoel J?nior
07-21-2011, 01:26 AM
You may watermark your pictures with external tools (e.g. download - watermark - upload). I will not add this feature for copyright reasons.
All the other requests may be possible, I'll think about it :)
Do not forget us (vb3.8) please my friend.
dartho
08-24-2011, 10:18 PM
Excellent. I came a cross an issuie where it would attempt to cache album pictures (vb 3.8.7), but instead it cache a 1x1px img? (vBulletin's cron ?)
This however didn't happen when attachments were used in img tags :confused:
To work around I added the following code to y2kswimgcache.php so that any images in the forums were not cached:
// Don't change local files ---------------------------------------
for($i = 0; $i < $n; $i++)
{
if(strpos($files[$i]['url'], $forum_home) !== FALSE)
{
$files[$i]['url'] = '';
}
}
Manoel J?nior
09-08-2011, 12:50 PM
Any news y2ksw??
Thanks
dartho
09-08-2011, 04:42 PM
This works well under 3.8.7!
y2ksw
09-09-2011, 07:48 AM
Any news y2ksw??
Thanks
No news yet ... overrun by work.
Very nice mod! works very well on 3.8.7, but I noticed a bug, when you give a space after the img bbcode, modification does not work.
y2ksw
02-21-2012, 08:54 AM
Very nice mod! works very well on 3.8.7, but I noticed a bug, when you give a space after the img bbcode, modification does not work.
It's not intended to have a space there ;)
If there are spaces, probably they are intentional in order to show the tags in the post.
dartho
05-18-2012, 03:01 AM
After minimal testing, your version of this for VB4 (https://vborg.vbsupport.ru/showthread.php?t=253309) works under vb 3.8 also ... (although there may be an issue with cron logging?)
adwade
08-15-2013, 12:47 PM
Please this version update:
- a scan and remove of unused images
One quick question: IS there any way to determine if a cached image is no longer in use?(i.e. a thread which had a cached-image in it has been deleted, but the cached-image remains) From what I've gathered reading this thread, if a thread is deleted and the cached-image is no longer needed it still remains (unused) in place. True?
This is a GREAT MOD and has kept our discussions meaningful, no matter how old they are by keeping the images within our threads intact. :cool:
Oh and I'll 2nd Manoel Junior's comment: Congratulations, you're a great developer.
y2ksw
08-16-2013, 09:26 AM
One quick question: IS there any way to determine if a cached image is no longer in use?(i.e. a thread which had a cached-image in it has been deleted, but the cached-image remains) From what I've gathered reading this thread, if a thread is deleted and the cached-image is no longer needed it still remains (unused) in place. True?
This is a GREAT MOD and has kept our discussions meaningful, no matter how old they are by keeping the images within our threads intact. :cool:
Oh and I'll 2nd Manoel Junior's comment: Congratulations, you're a great developer.
If a thread is deleted and the cached-image is no longer needed it still remains (unused) in place: True
Because a post may be copied inside and even outside your forums and their images are still in use. Since you link images statically to your site, you are becoming the primary source of that copy, if the original disappears for one or another reason.
I am aware of the space problem, but in the very long run, old images may become very interesting to researchers. And thus, new people are coming to your site, only because you got what they need :)
adwade
08-16-2013, 11:33 PM
I am aware of the space problem, but in the very long run, old images may become very interesting to researchers. And thus, new people are coming to your site, only because you got what they need :)
I understand and can agree with your logic. :up:
I'm running v1.0.2.0 on vB3.8.6 and it's run flawlessly since I installed it w-a-y back when.(i.e. vB 3.6) My only concern is how many images can I hold in just ONE directory, before it blows up on me? :eek:
And along those lines, is there any way to patch/modify the version I'm running to keep-it-going?(i.e. as Focus2 suggested in post #150 (https://vborg.vbsupport.ru/showpost.php?p=2021088&postcount=150) of this thread)
dartho
08-17-2013, 02:01 AM
I haven,t looked, but if the number of images in a single directory is the concern, you should be able to modify the code to start placing images in a new directory and leave the existing intact. All existing cached images will still be accessible in their original path and all new ones will go to the new directory? Set a reminder to change things again next year ...
adwade
08-17-2013, 06:23 PM
Yes, the number of images in a single directory is my concern. I just don't want it to stop working.
Focus2's suggestion in post #150 (https://vborg.vbsupport.ru/showpost.php?p=2439273&postcount=150) is for v1.0.3.0 I think, because I saw the 'png' in the code referenced.
I'm not a coder at all, but given direction I can usually find/replace small segments of such and not tear things up.
Thanxx for the answer though, because I was unsure what the MOD would do with old/existing images in the cache. Now at least I sort of know a work-around is possible for v1.0.2.0 if I can find code similar to what Focus2 was referring to. I just don't want to start renaming all my images (from this point forward) to png, if I don't have to.(i.e. the simpler, the better for me)
y2ksw
08-18-2013, 04:24 PM
I understand and can agree with your logic. :up:
I'm running v1.0.2.0 on vB3.8.6 and it's run flawlessly since I installed it w-a-y back when.(i.e. vB 3.6) My only concern is how many images can I hold in just ONE directory, before it blows up on me? :eek:
And along those lines, is there any way to patch/modify the version I'm running to keep-it-going?(i.e. as Focus2 suggested in post #150 (https://vborg.vbsupport.ru/showpost.php?p=2021088&postcount=150) of this thread)
If your system is Linux, it won't blow quickly :)
The new version does divide the images.
You may try to change the folder from code and create a new one respectively to this change. But, please test it before ;)
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.