Cache busting for images in Drupal 7 and lightbox 2 Scenario: I have content type with a field 'images' (Widget: plupload). View created and displayed on Home page. View has Formatter: LightBox2, LightBoxType: Single Lightbox, Image-Style: thumbnail image-style for the images. Whenever user click on image, LightBox2 shows original image.

Problem: Everything working fine. But the images are getting cached in browser cache. Hence I followed https://www.drupal.org/node/2313539 Cache Busting discussion and changed theme.inc theme_image() function. Now the thumbnails have time(cache busting string) in their name but lightbox still the same.
I get the point that i have write or hook the formatter as well to make it work in views. Not sure where and what should change in LightBox module or elsewhere.

This is what HTML looks like on page 

&lt;a href="sites/default/files/images/3.jpg" rel="lightbox[field_images][&lt;p&gt;&lt;a href="sites/default/files/images/3.jpg" title="Download Original" download=""&gt;Download Original&lt;/a&gt;&lt;/p&gt;]" title="" class="lightbox-processed"&gt;***&lt;img typeof="foaf:Image" src="sites/default/files/styles/app-thumbs/public/images/3.jpg?itok=-OKZ8zZW&amp;hash=2563415" width="200" height="200" alt=""&gt;&lt;/a&gt;


where &lt;img&gt; tag has src url appended with '&amp;hash=2563415' i.e. cachebust string, but anchor-element doesn't have the same.
Any ideas how to make Lightbox2 anchor element to include cachebust string element as well.
Drupal version:7.41, LightBox2
OK, I solved it. Cachebuster can be implemented as discussed in shared url for drupal 7 by editing includes/theme.inc, and theme_image function. Just add attributes['src']with a random string say time().
Further, lightbox2 module can be tweaked to append random string in a href, by editing lightbox2/js/lightbox.js, just edit start: function(imageLink, slideshow, lightframe, lightvideo, lightmodal) {} and append anchor.href with new Date().getTime().

These two tweaks will make sure that drupal is giving img src appended with time and lightbox2 inserting time() in anchor href.
Browser will never cache these images.