Index: js/jlightbox_image.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jlightbox/js/jlightbox_image.js,v
retrieving revision 1.1.2.2
diff -u -p -r1.1.2.2 jlightbox_image.js
--- js/jlightbox_image.js	8 Jan 2008 07:59:17 -0000	1.1.2.2
+++ js/jlightbox_image.js	31 Jan 2008 00:13:25 -0000
@@ -5,11 +5,30 @@
  * Automatically adds all images in a displayed node to one jLightbox gallery.
  */
 if (Drupal.jsEnabled) {
-		$(document).ready(function() {
-				$('.inline a img.image-thumbnail').parent().each(function() {
-					this.rel = 'lightbox[image_thumbnails]';
-					this.href.replace('.thumbnail', '');
-					$(this).attr({onclick: '', title: $('img', this).attr('title')});
-				});
-		});
+    $(document).ready(function() {
+        // Image Assist thumbnails.
+        $('.inline a img.image-thumbnail').parent().each(function() {
+          if (typeof this.href != 'undefined') {
+            this.rel = 'lightbox[image_thumbnails]';
+            this.href.replace('.thumbnail', '');
+            $(this).attr({onclick: '', title: $('img', this).attr('title')});
+          }
+        });
+        // Image Gallery thumbnails.
+        $('.images img.image-thumbnail').parent().each(function() {
+          if (typeof this.href != 'undefined') {
+            this.rel = 'lightbox[image_gallery]';
+            this.href = this.firstChild.src.replace('.thumbnail', '');
+            $(this).attr({onclick: '', title: $('img', this).attr('title')});
+          }
+        });
+        // Image Attach thumbnails.
+        $('.image-attach-teaser img.image-thumbnail, .image-attach-body img.image-thumbnail').parent().each(function() {
+          if (typeof this.href != 'undefined') {
+            this.rel = 'lightbox[image_gallery]';
+            this.href = this.firstChild.src.replace('.thumbnail', '');
+            $(this).attr({onclick: '', title: $('img', this).attr('title')});
+          }
+        });
+    });
 }
