Compression mode of the first thumbnail.

Syntax

Initialize
JavaScript CopyCode imageCopy Code
<script type="text/javascript" src="iuembed.js"></script>
<script type="text/javascript">
var iu = new ImageUploaderWriter("ImageUploaderID", 610, 500);
//...other params...
iu.addParam("UploadThumbnail1CompressionMode", "*.* = Jpeg");
//...other params...
iu.writeHtml();
</script>
Get/Set Value in Runtime
JavaScript CopyCode imageCopy Code
getImageUploader("ImageUploaderID").setUploadThumbnail1CompressionMode(value);
value = getImageUploader("ImageUploaderID").getUploadThumbnail1CompressionMode();
Property Value

A string value that specifies the compression mode format string of the first thumbnail.

The compression mode format string consists of file masks=compression modes pairs separated by semicolon. Each pair includes the set of file masks and the set of compression modes separated by comma. In general, this string has the following syntax:

mask11,mask12,...=mode1,mode2,...;mask21,mask22,...=mode1,mode2,...;...

When Image Uploader prepares a POST request it parses the compression mode format string from beginning to end and extracts file masks=compression modes pairs. For each file selected for upload Image Uploade gives the first pair. If it finds the file mask in this pair corresponded to extension of the file, it applies the first appropriate compression mode from the compression set of this pair. Otherwise if no appropriate file mask or compression mode found, Image Uploader checks the next pairs in the same manner.

Image Uploader supports the following compression modes:

Compression Mode Description
Jpeg If a file selected for upload is image, Image Uploader resizes this image to the specified dimensions and uploads it as JPEG file. Otherwise if file is non-image, Image Uploader uploads a system icon associated with the file. By default, this mode is applied to any file regardless of its extension. More information about image resizing before upload you can read in the Resizing and Rotating Images topic.
Zip Image Uploader sends a ZIP archive of the original file.
Icon Image Uploader sends a system icon associated with a file selected for the upload.
SourceFile Image Uploader sends the original file.

Default value is "*.* = Jpeg".

See Also

Examples
Handling Files Compression
POST Field Reference

Reference
UploadThumbnail1BackgroundColor Property
UploadThumbnail1CompressOversizedOnly Property
UploadThumbnail1CopyExif Property
UploadThumbnail1CopyIptc Property
UploadThumbnail1FitMode Property
UploadThumbnail1Height Property
UploadThumbnail1JpegQuality Property
UploadThumbnail1ResizeQuality Property
UploadThumbnail1Watermark Property
UploadThumbnail1Width Property