A Thumbnail Property is a special property that can be used on Image objects to create a custom thumbnail image.

A Thumbnail Property


Structr will create custom-sized preview Images (aka thumbnails) for any image stored in Structr’s virtual filesystem automatically. There are two built-in default sizes optimzed for the Structr User Interface: 300x300 and 100x100 pixels.

If an application requires custom-sized thumbnails, this property can be used.

The dimensions of the custom thumbnail image can be specified in the Format/Code field. The values are expected as a comma-separated list in the following format:

width:  Integer
height: Integer
crop:   Boolean (optional)
JSON Output
	"query_time": "0.000897187",
	"result_count": 1,
	"result": {
		"thumbnail": {
			"id": "534ad12ecd3d4a8e972ac5055ca86565",
			"contentType": "image/png",
			"size": 5660,
			"isFile": true,
			"type": "Image",
			"name": "image.png_thumb_200x100",
			"width": 200,
			"height": 100,
			"tnSmall": null,
			"tnMid": null,
			"isThumbnail": true,
			"path": "/image.png_thumb_200x100",
			"isImage": true
   	"serialization_time": "0.000051543"


Related Articles
About this article
Last change 2017-08-25
Topics Structr 2.0