Solved

Lightbox doesnt work: Image gallery using drupal: Lightbox2, CCK, Views, ImageCache

Posted on 2010-09-06
5
678 Views
Last Modified: 2012-05-10
Hi,
We have a website with an image-gallery:
http://relaunch.ethik.or.at/fotogalerie

This was ceated using CCK imagefield, imagecache and views. We want to use Lightbox2 and this module has also been activated. But somehow, when I click on the images, instead of lightbox only the image appears. What did I do wrong?
This tutorial uses a very similar approach:
http://jamestombs.co.uk/2009-03-18/create-a-simple-image-gallery-in-drupal-6-using-cck-and-views/996

I have also deactivated the Views AJAX capability, but it doesn't work there either.

Please advise. Thanks.
0
Comment
Question by:aboutadream
  • 2
  • 2
5 Comments
 
LVL 19

Assisted Solution

by:Albert Van Halen
Albert Van Halen earned 400 total points
ID: 33613451
Your're creating two menus with smoothmenu.
The first is on an alement with id smoothmenu1
The second is on an element with id smoothmenu2 -> this one does not exist.

Correct this error first...
0
 

Author Comment

by:aboutadream
ID: 33613610
Thanks, yeah I had initialized two menus in the template for vertical menus, which I did not yet implement. I removed those lines, but lightbox behaviour has not improved.
0
 
LVL 10

Assisted Solution

by:mstrelan
mstrelan earned 100 total points
ID: 33613721
Is your view set up to use Fields or Nodes? If it is fields you should be defining the image field in the view. In the settings for that field you can choose something like Thumbnail of image linked to Lightbox
0
 
LVL 19

Accepted Solution

by:
Albert Van Halen earned 400 total points
ID: 33613805
The problem lies in lightbox2_image_nodes function (in auto_image_handling.js)
You're calling lightbox2_init_triggers with settings which are empty
Only the first statement (with settings.trigger_lightbox_classes) is working. The rest will result in an error causing your lightbox to fail.

Correct the errors in Drupal.Settings object.
0
 

Author Closing Comment

by:aboutadream
ID: 33651497
Thanks a lot. The javascript problem, was a great hint. It is a problem of the drupal module, I guess, where I have to provide some additional arguments (Image-Description), to get the modules FileFields, CCK, ImageCache and LightBox2 running. I have to try it, haven't totally figured it out, but thanks to you I am on the right path.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question