Hi, I've setup a gallery solution based on the brilliant HOW TO: Create an image gallery using CCK and Views (not Image Module). However, I would like to keep thumbnails to link to the actual node (to enable comments, rating etc) - and activate Thickbox gallery view through a separate gallery-wide "View slideshow" link. I've looked briefly at the Thickbox code, and it seems if that I can remove the thickbox class from the images and keep the rel attribute I might be close to the solution. Then have a link with thickbox class set, that points to the first image. But I'm only speculating here and haven't come up with a clean solution yet. Any ideas on how this can be achieved?

As for now, I have image thumbnails that trigger thickbox - and titles that link to the corresponding node. But I think that might be unintuitive for the user and it doesn't encourage valued node-activities such as rating and commenting on images.


Tim99’s picture

I am also interested in a "View slideshow" link. Are there any news about this?

jrust’s picture

Here's how I added a View Slideshow link:

    foreach((array)$node->field_image_cache as $key => $item){ 
      $attribs = $key > 0 ? array('style' => 'display: none') : array('id' => 'first-image');
      print theme('imagefield_image_imagecache_thickbox', 'product', array('type_name' => 'product'), $item['filepath'], $item['alt'], $item['title'], $attribs);

And then somewhere where you want to link to the slideshow:

    <a href="#" id="view-images" onclick="var o = $('#first-image').get(0).parentNode; tb_show(o.title, o.href, o.rel); return false;">View Slideshow</a>