Have you ever wondered if Liferay offer image scaling out of the box? Yes it does, you only need to enable this option!
In portal-ext.properties add:
The second property image.hook.impl sets the hook implementation to be used to trigger automatic data migration during an upgrade.
Requesting Scaled Images
Now in order to request scaled images simply use height and width as GET parameters, like so:
For performance reasons Liferay caches scaled images. Please refer to ImageUtil API for more information.
Further information can be obtained by consulting the Image section in the Liferay Portal 6.1 – User Guide.