Hello Community - We have an image component, in that authors will be selecting images. without having any separate field selection of the image type/extension in the dialog, I wanted to retrieve the selected image extension and based on that, we will perform some logic. is there a way to retrieve the image extension of the selected image in HTL.
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Check below code to get the image extension from image resource
Image image = new Image(resource); // resource - image resource
image.getExtension();
For more details, please refer
Hope this helps!
Hi,
Check below code to get the image extension from image resource
Image image = new Image(resource); // resource - image resource
image.getExtension();
For more details, please refer
Hope this helps!