Axllent\ScaledUploads\ScaledUploads
Automatically scale down uploaded images ========================================
Extension to automatically scale down uploaded images to a maximum
of pre-determined values or defaults. It also includes auto-rotation
based on EXIF data (eg: images from digital cameras).
Options:
Please refer to the README.md
- Author: : Techno Joy development team (www.technojoy.co.nz)
- License: : MIT-style license http://opensource.org/licenses/MIT
Synopsis
class ScaledUploads
extends Extension
{
- // members
- private static integer $max_width = 960;
- private static integer $max_height = 800;
- private static boolean $auto_rotate = true;
- private static boolean $bypass = false;
- private static boolean $force_resampling = false;
- private static array $custom_folders = ;
- // methods
- public Null onAfterLoadIntoFile()
- private Null scaleUploadedImage()
- private Int exifRotation()
Hierarchy
Extends
- SilverStripe\Core\Extension
Uses
- SilverStripe\Core\Config\Configurable
Members
private
- $auto_rotate
- $bypass
- $custom_folders
- $force_resampling
- $max_height
- $max_width
Methods
private
- exifRotation() — exifRotation - return the exif rotation
- scaleUploadedImage() — Scale an image
public
- onAfterLoadIntoFile() — Post data manupulation