Resize attachments all

Resize attachments all 2.3

No permission to buy ($35.00)
Compatible XF 2.x versions
  1. 2.3
Premium upgrade:

This XF2 add-on along with the entire collection can be purchased for $35.00 USD. Your Premium upgrade will allow you to download as many XF2 add-ons as you like for one year. Please see the entire collection located in the Resources area at this URL:

https://www.xf2addons.com/

Description:

Resize all attached images which are over maximum width and height allowed.

(Example of Resize attachments all page)

pic001.webp


Example of Rebuild caches page)

pic002.webp


(Example of Options page)

pic003.webp


(Example of Maximum attachment image dimensions selection)

pic004.webp


Maximum attachment image dimensions selection:

Although the screenshot above says you can use 0 or blank, this add-on requires you to use a positive value for the Maximum attachment image dimensions settings. I suggest using 2500 x 2500.

Admin control panel -> Setup -> Options -> Attachments -> Maximum attachment image dimensions

How to use:

In your browser add resizeattachmentsall to your forum URL. This will show just how many attachments need to be resized.

If you have less than 10000 attachments that need to be resized, run from the Rebuild caches page:

Admin control panel -> Tools -> Rebuild caches -> Resize attachment all

If you have over 10000 attachments that need to be resized, run from CLI.

How to run from CLI:

In cPanel click the Terminal link.

Change directory to where XenForo runs, this is typically in the public_html directory.

cd public_html

Enter the following command:

php cmd.php xf-rebuild:resizeattachmentsall

Questions and Answers:

Q: Will this add-on exclude GIF attachments?
A: Yes.

Q: If the Rebuild CLI stalls, can I restart from the last data_id displayed?
A: Yes just enter that number into the Options page Data ID start field and start the CLI command.
  • Like
Reactions: t0fx
Author
AndyB
Views
3,443
First release
Last update

Ratings

5.00 star(s) 1 ratings

More resources from AndyB

Latest updates

  1. See description

    Resize attachments all v2.3 changes: Now shows exactly how many attachments need to be resized.
  2. See description

    Resize attachments all v2.2 changes: Added code to suppress server error if image is corrupt.
  3. See description

    Resize attachments all v2.1 changes: Now works with GD or Imagick. Now resizes JPG, PNG and...

Latest reviews

This is a must have add-on, and it works great just as long as you have the ImageMagick PECL extension.
Back
Top Bottom