Resizing of uploaded images (image field)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nunos
    Member
    • Mar 2018
    • 94

    Resizing of uploaded images (image field)

    Good afternoon,

    Is there a way of resizing the uploaded image of an image field?

    What i will like to achieve is that when you upload a new image, the system will automatically resize the image to a custom size and with custom quality.

    For example all uploaded images will be resized to 1920*1080 in JPG format with a quality of 85%

    Thanks,

    Nuno
  • esforim
    Active Community Member
    • Jan 2020
    • 2204

    #2
    Nope, will require coding.

    Not sure if it even possible with the current extensions/PHP dependency. I know resize is "possible" using the PDF Template and EspoCRM can also generate thumbnails for attachment but that is not the same as Image conversion which is what you trying to do.

    Comment

    • item
      Active Community Member
      • Mar 2017
      • 1476

      #3
      Hello,

      not looked library in github .. but it can be done with a hook afterSave, just check if image is image

      PHP Image Processing. Contribute to Intervention/image development by creating an account on GitHub.

      intervention.io is the creator of solid and well-crafted open source software in PHP including the popular library Intervention Image. Simplify your development with our user-friendly packages.

      intervention.io is the creator of solid and well-crafted open source software in PHP including the popular library Intervention Image. Simplify your development with our user-friendly packages.


      This library seemt better : https://github.com/spatie/image
      Last edited by item; 08-17-2020, 05:55 PM.
      If you could give the project a star on GitHub. EspoCrm believe our work truly deserves more recognition. Thanks.​

      Comment

      Working...