Resize Attached Images (Updated for 2.0 RC4)

Started by Kays, October 17, 2009, 04:19:10 PM

Previous topic - Next topic

Makar

Configuration settings are taken from the attached settings

Sorry for my english

Kays

There are no admin controls for 1.1.x. The compression is set at 85 and the image size is the same as for linked images under Features and Options in the Admin CP.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

fotis3d

Then unfortunately this mod doesn't work for me since i want the linked at 750px and the attached at let's say 1280px.
And also i needed to be able to change the compression (of course i believe this could be done through coding )

too bad

:-[

fotis3d

Is there a way to change the compression setting for smf 1.1.11 ?

Edit: Nevermind i got it  ;)

But is there a way of changing the code so that it won't get the size from smf but just put the wanted numbers in the code ?

Glasso


wickedgood


dmacleo

yeah I liked this on rc3, tried install on rc4 and it failed for me.

spinus


fiver

SMF 2.0 RC 3


I installed this many months ago, and during installation I selected
- Reformat non-JPEG images to JPEG
- Resize existing images
After installation, all the images before installation only shows thumbnails. When clicked, it shows a browser empty image icon.


I deselected these 2 settings and it didn't revert or repair the damaged attachments. How do I get the hundreds of old attachments back please?





Glasso


Kays


If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

Glasso


willerby

I don't know how I have missed this mod but have been searching for a simple image upload mod for two years. I've used everything offered for external hosting services because my users are all non-techie types who try and upload 5Mb digital images and can't get the hang of reducing photos despite step by step instructions in a variety of ways. But all the external mods either failed, required the user to cut and past links etc or got dropped by the mod authors.

This is one awesome mod. Installed on RC4, tested, resized existing images and love it. Have been able to remove all restrictions on image file size and dimensions for attachments and now users have no excuse.

Thank you Kays... elegant and simple, and most importantly it does what it says...
What type of washing machine is September?

An autumnatic. :)

Kays


If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods


Kays

Are the original images still on the server? Look at the dlattach number for that image. Then check the database for it and the attachment folder. All attachments are now named with the id number as the first digits before the underscore. Followed by the file_hash.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods


Spuds

@Kays

Noticed a small issue on RC4 whith the modification in Subs-Post.php, where you add in the section of // Did the mime type change during reencoding?

Part of the added code uses $validImageTypes (in case getimagesize does not return a valid image mime) but $validImageTypes is not initiated until after that point in the code.


Kays

Thanks for noticing that Spuds. It looks like the devs moved a few things around and I missed it. ::)

I've changed the search position to be after $validImageTypes is initialised and updated the mod. You will need to uninstall the old version first.

@ spinus, your welcome. :)

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

TomW

Thanks for the update, and for changing the file naming logic !

Advertisement: