The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Server-side Thumbnailed Attachments Details »» | |||||||||||||||||||||||||
Thumbnailed Attachments Version 1.0
Description: Its kind of Self explanitory, but in anycase if you dont know what it does, it checks if an attached image is larger than your specified size and if it is it will use ImageMagick, Netpbm, or the GD Image functions to resize it accourdingly using a rather simple formula to make sure the thumbnails are kept in scale. Usual Mod Warning: This moddification unlike most other thumbnailed attachment mods isn't only a template hack so mind you, you'd have to make sure you backup your files before using this hack. Screenshots/Test Threads: I have one included below and this link contains a vB that has already been modded: http://www.cheatandwin.com/forums/sh...=&threadid=216. But i should let you know that both are kind of outdated already since i did update the instructions from an oversight i had made earlier.. Requirements: Umm, as vB goes i'd say you'd need 2.2.x or higher but i designed it under 2.3.3 so there might be slight differences namely in the templates but not much to worry about that.. PHP 4.0.6 <- For the moment that is the minimum requirement for the modifications i have made aside to the ones required for vB Any of the following 3: ImageMagick, Netpbm, or GD 2.01 or higher Thats about it, any comments, suggestions, or questions feel free to post here or even email me personally at cvmagic at cheatandwin dot com. [edit] New Updated Version Download Today! Show Your Support
|
Comments |
#22
|
|||
|
|||
CVMagic - excellent hack - this is how hacks should be made, clean simple, not much modification. Thank you kindly!
|
#23
|
||||
|
||||
Hmm...well I added the script but I'm getting broken images now and when you click on the broken thumbnail image it takes you to the real picture.
|
#24
|
||||
|
||||
that is odd, can you add '&dl=1' to the attachment url and post the results of the error..
|
#25
|
||||
|
||||
Okay, I debugged the issue, and it was a simple error in my part that my version of php for windows didnt pick up which i odd i must say so here is the simple fix
Code:
----------- find ----------- if($dc=0){ ----------- Replace with ----------- if(!($dc==1)){ ########### Done ^_^ |
#26
|
||||
|
||||
Nice hack, however I have a problem. I set the max size of an image to 200x200 and the size to 1 mb. I try to upload a file that is 500x400 and vb warns that the image is too big to upload. (Exceeds the 200x200 I set)
I am on VB 2.3.3 I have no other hacks installed in the attachments.php I ran the Sql quarries and verified there existence in the db I triple checked the php additions I have disable GD 2+ and tried enabled as well I set the imagemagak 2 1 and have the exact path. It is making a image to the thumbs folder but not the size I told it to. "150x150" If I up the size of my image allowance it uploads the image and does say "Click here to enlarge" but the image in the thread is the same size as the attached image in the thread. Hope I explained this well enough. Let me knoe if not. Chuck |
#27
|
|||
|
|||
Had some problems getting this to work.
The problems I've encountered were: 1. The main problem is because it resizes on the fly when a page loads. If you're applying to this hack to a busy site, you can sometimes as we do have 5+ images in a thread. Although it seems to work when there's just one image, any more and it seems like the script doesn't have long enough to complete the conversion and you end up with broken images, and corrupt files in the thumbs dir. Is there any way to give the script time to generate the thumbnails. Alternatively if a script could be created to convert all images store in the directory in one hit, might take some time, but its where you'll eventually end up - and I think it can cope with converting one image on a thread as a new post is made. 2. ImageMagick worked in that it created a resized thumbnail but for some reason it generated the name without quotes - but the script is expecting those since it uses the php function escapeshellarg for the filename. Anyone know a way round this? 3. Couldn't get NetPBM to reduce the image size, it simply created a copy of the oversized image to display. Great hack, and potentially what I've been looking for - but unworkable on my forum unfortunately. Any assistance much appreciated. |
#28
|
||||
|
||||
:-P what can i say, sorry about the delay... i should note that with safemode this hack does not run well at all, I didnt code it with making it safemode compatible in mind at all..., but as in multiple images at a time, it should work just fine because w/o safemode the images have all the time in the world to complie its thumbnails and plus if a user were to press stop it still continues on its own(again not safe mode compatible)... but noted i was using a much older version of netphm and imagemagick so it might not work as i intended at all, but dont worry at all im working on a newversion that instead of processing the attachment on post view it will do it during the post thus be safemode compatible in a sence...
|
#29
|
||||
|
||||
Quote:
|
#30
|
|||
|
|||
Can you help me CVMagic?
In my forum, I obtain any broken thumbnails, look: http://www.indicedivx.com/foro/showt...threadid=24416 OR http://www.indicedivx.com/foro/showt...threadid=23930 (You need register for show thumbs. Login: testing, pass: testing) Thanks |
#31
|
||||
|
||||
I've PMed you on your site already with the name: CVMagic, but in anycase if you have blocked out PMs, there might be 2 issues one that the file was somehow interupted during thumbnail generation which your solution would to be just deleting all the thumbs and let the script generate all the thumbs again, if its the second issue til this day gets me which is the your using GD2 it as some problem with some gif files and wont allow it to go beyond reading it at all which then i'd just either recommend disabling gif file uploading or getting Imagemagick or Netphm with gif/jpeg/jpeg2000/png support and using them as your method to thumbnail images...
[edit] There is another method too, actually its a work around if you dont want to install those other 2 programs, it means that those bad gif files will go unresized but hey its alot better than an X no? well here is the code you need to replace: PHP Code:
PHP Code:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|