converter.autoReduceDimensions Property HTML5/Flash Uploader JavaScript

Supported technologies:

Gets or sets a value specifying what to do if the browser does not allow creating resized copies of specified size.

Syntax

JavaScript Initialize
$au.imageUploaderFlash({
    converters : [
        {
            //...other params...
            autoReduceDimensions: true,
            //...other params...
        }
    ]
})
Get/Set Value at Runtime
$au.imageUploaderFlash('uploaderID').converters().set(index).autoReduceDimensions(value);
value = $au.imageUploaderFlash('uploaderID').converters().get(index).autoReduceDimensions();

Property Value

Type: Boolean

If true, the browser will try to produce an image of smaller size (max possible in this browser). Otherwise, it will fail and no image is uploaded.

Default value is true.

Remarks

Not all browsers are memory friendly enough to generate large images. For example, Safari on iOS cannot create image larger than 5Mpix (very old iPhones - not more than 2MPix). Firefox and IE are limited by 32Mpix.

This parameter is used to define a strategy, the uploader should use to handle this situation. If you set true, you say "give me as a large image as you are able to generate". However if it is not acceptable (for example, a user places an order for printing), you can set false and the uploader will handle it as if it is a non-image file.

It makes sense setting it to false only if you set the fallback option in the mode property, for example "*=Thumbnail;SourceFile". This way you will receive an original file if the uploader failed to create a resized copy.

See Also

Reference