You need to sign in to do that
Don't have an account?
Varghese Kiran
To compress image size while querying image from attachment
In my website I am querying more than 10 images from Attachments to show it in the page. Among these images, only one will be the main image and all others will be thumbnails. What I am doing right now is after querying the attachments, I have given specific size to the thumbnail and main image. This query generates more than 85% data of the site. Is there any way I can minimize the image size(by using code) or can I do anty modifications on the query so that I could reduce the site data. All suggestions are welcome.
You can use this trick to show images on page . it will not take data from query.
<apex:image url="/servlet/servlet.FileDownload?file={!attachment.id}" />
Your answer may be here :
https://wordpress.org/plugins/wp-smushit/developers/
http://www.smashingmagazine.com/2014/02/03/one-solution-to-responsive-images/
I got a new link ,i think it will useful for u ..
http://bobbuzzard.blogspot.in/2014/11/responsive-images-in-visualforce.html
Thanks for your reply.
I think, inorder to implement this using Picturefill, I should provide two different images. One for thumbnail and other for main image.Since there are so many images in my instance, it is not a feasible solution to created low sized images for all images.