News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Automatic Attachment Rotation (and Resize)

Started by dougiefresh, March 04, 2016, 07:34:59 PM

Previous topic - Next topic

Diego Andrés

Quote from: dodos26 on September 18, 2022, 06:27:44 AMThe way your mental denial is amazing. You create logical error due to illogical reading and then blame someone for your mistakes.

Surely is not that fact that you're are requesting features unrelated to this mod?
Who is she blaming? There's no "per type" control in the attachments system.

SMF Tricks - Free & Premium Responsive Themes for SMF.

elexx

#401
I wanted to make the suggestion that a function that not only rotates a single image that has been posted for a long time, but also reduces it, would also be a great function. I read the help again and found that it already exists: "Manual Resizing of Existing Images"  8)  It might be great to have this item available in the Rotate/Flip menu as well.
Thank you for the extremely helpful addon!

GL700Wing

#402
Quote from: elexx on October 02, 2022, 06:26:32 AMI wanted to make the suggestion that a function that not only rotates a single image that has been posted for a long time, but also reduces it, would also be a great function. I read the help again and found that it already exists: "Manual Resizing of Existing Images"  8)  It might be great to have this item available in the Rotate/Flip menu as well.
Thank you for the extremely helpful addon!
Have you tried enabling the "Resize, reformat and/or compress existing images when they are displayed" option?
Life doesn't have to be perfect to be wonderful ...

sam666

Major change introduced in v6.00
o - Support for SMF 2.0.18 and PHP 7.4.

Will 2.0.19 and PHP8.0 be supported in the near future?
Many thanks for keeping this mod supported.

GL700Wing

Quote from: sam666 on October 05, 2022, 01:16:10 PMWill 2.0.19 and PHP8.0 be supported in the near future?
Many thanks for keeping this mod supported.
Not sure - I don't know what's involved in adding support for these versions.

I'm currently away on holidays so I'll look into to this when I have time after I return (hopefully mid-late November).
Life doesn't have to be perfect to be wonderful ...

Rheingauner

#405
We have some problems with your mod under PHP 7.4.32, PHP 8.0 and 8.1.1. Under "PHP 7.4.3 by OS vendor" your mod works great.

OS = Ubuntu 20.xx (latest updates are installed) with plesk-panel, SMF-Version 2.1.2

Under PHP 7.4.32, PHP 8.0 and 8.1.1 there are no changes in the picture size when we change the quality for example from 70 to 50, with "PHP 7.4.3 by OS vendor".

There are serious differences in file sizes between php 7.4.3 and the other versions.

Sorry for my bad english.

Kind regards Rheingauner

Filename ending with _50 or _70 means the quality setting

GL700Wing

Quote from: Rheingauner on October 25, 2022, 11:21:57 AMWe have some problems with your mod under PHP 7.4.32, PHP 8.0 and 8.1.1. Under "PHP 7.4.3 by OS vendor" your mod works great.

OS = Ubuntu 20.xx (latest updates are installed) with plesk-panel, SMF-Version 2.1.2

Under PHP 7.4.32, PHP 8.0 and 8.1.1 there are no changes in the picture size when we change the quality for example from 70 to 50, with "PHP 7.4.3 by OS vendor".

There are serious differences in file sizes between php 7.4.3 and the other versions.

Sorry for my bad english.

Kind regards Rheingauner

Filename ending with _50 or _70 means the quality setting

Which image converter extension are you using - GD or iMagick?

Also, when you switch between the different versions of PHP are you ensuring that the GD and/or iMagick extensions are enabled?

The reason I'm asking is because it is the image converter that determines the final file size and what the resized image looks like - all the mod does is use the image converter you've configured in the mod (ie, GD by default if it is enabled and iMagick if the extension is enabled in PHP  and the associated option is enabled in the mod).

Finally, I haven't tested this mod with PHP 8.x so I really have no idea how the GD and/or iMagick image converter extensions process images.
Life doesn't have to be perfect to be wonderful ...

Rheingauner

Under "PHP 7.4.3 by OS vendor" is only GD working, iMagick is not selectable. iMagick and GD are always enabled with the other PHP Versions. If iMagick ist disabled the filesize is nearly by the original jpg size.

GL700Wing

Quote from: Rheingauner on October 26, 2022, 08:49:10 AMUnder "PHP 7.4.3 by OS vendor" is only GD working, iMagick is not selectable. iMagick and GD are always enabled with the other PHP Versions. If iMagick ist disabled the filesize is nearly by the original jpg size.

Given that the resizing works correctly with "PHP 7.4.3 by OS vendor" it seems there is an issue with the implementation of the PHP GD/iMagick extensions in your other operating system and unfortunately I can't help you with that.

I suggest that you ask for help from the relevant Ubuntu/Plesk support communities.
Life doesn't have to be perfect to be wonderful ...

dodos26

#409
Quote from: dodos26 on September 17, 2022, 11:55:57 AMYou can add permission to see image attachments for guests.

The solution in case someone came across the same question publication.


Code block removed by mod author because, and as the author of this post has previously been advised, this mod has nothing to do with how, when or where image attachments are displayed.

SeaChaser

Is there an upgrade to 6.16 needed for SMF 2.1.3?

I am getting the installation error below:


GL700Wing

Quote from: SeaChaser on February 27, 2023, 01:15:27 PMIs there an upgrade to 6.16 needed for SMF 2.1.3?
Possibly but I'm currently away on holidays and won't get an opportunity to investigate this issue and/or update the mod for another month or so.
Life doesn't have to be perfect to be wonderful ...

landyvlad

Cool really looking forward to the update for compatibility with 2.2.3 and on.

(because as stated it doesn't work for 2.1.3 even if stating to install emulating 2.1.2)

I hope you're enjoying your holiday mate :)
"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

petewadey

None of my older attachments are loading, and on investigation in my cpanel file manager, I notice the attachments no longer loading have been compressed, so are no longer jpg's but are ( gzip compressed data, from Unix, last modified: Thu Dec 30 01:18:29 2021, max speed )
Is this possibly anything to do with this mod?
   

Diego Andrés

If you are on 2.1.3, it's possible as the mod doesn't fully work on the latest patch.

SMF Tricks - Free & Premium Responsive Themes for SMF.


GL700Wing

Quote from: petewadey on March 21, 2023, 09:04:58 AMNone of my older attachments are loading, and on investigation in my cpanel file manager, I notice the attachments no longer loading have been compressed, so are no longer jpg's but are ( gzip compressed data, from Unix, last modified: Thu Dec 30 01:18:29 2021, max speed )
Is this possibly anything to do with this mod?
   
@petewadey - Nothing to do with this mod - it does not do any file compression ...
Life doesn't have to be perfect to be wonderful ...

Sir Osis of Liver

Installed ver. 6.16 in 2.0.19, php 7.4/8.0.  Getting a lot of these -


https://www.thekrashsite.com/ferrarum/smf/index.php?action=dlattach;attach=25;type=avatar
2: Trying to access array offset on value of type null
File: /home/thekrash/public_html/ferrarum/smf/Sources/Subs-AutoRotation.php
Line: 477

https://www.thekrashsite.com/ferrarum/smf/index.php?action=dlattach;attach=25;type=avatar
Path cannot be empty


Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

GL700Wing

Quote from: Sir Osis of Liver on April 08, 2023, 10:40:58 PMInstalled ver. 6.16 in 2.0.19, php 7.4/8.0.  Getting a lot of these -

https://www.thekrashsite.com/ferrarum/smf/index.php?action=dlattach;attach=25;type=avatar
2: Trying to access array offset on value of type null
File: /home/thekrash/public_html/ferrarum/smf/Sources/Subs-AutoRotation.php
Line: 477

https://www.thekrashsite.com/ferrarum/smf/index.php?action=dlattach;attach=25;type=avatar
Path cannot be empty
Are you able to give me any info on how to reproduce this error?

Version 6.16 was released almost one year ago and this is the first time this error has been reported and it has not occurred on any of the three SMF 2.0.19 forums (all with PHP 7.4) that I manage.
Life doesn't have to be perfect to be wonderful ...

Sir Osis of Liver

Not really sure what's happening.  Trying to update my oldest forum (Oct 2010) to run in php 8.0 with responsive theme (customized Nightbreeze).  Started with the theme, then everything went sideways, lot of mod errors.  I've restored files/database back to Apr 1 and reverted to old theme and everything's working nicely in 8.0, no errors.  This mod is currently uninstalled, will install it tomorrow and see what happens.  Host is migrating my account to new cloud platform sometime tonight, don't want to be in middle of something when they pull the plug.  I suspect it's a theme issue, I've installed the mod on several forums without problems.  Will let you know once I've got it reinstalled.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Advertisement: