BipadTaranMahato / slideshow

Automatically exported from code.google.com/p/slideshow
0 stars 0 forks source link

Lightbox integration not working #84

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Note: If this is a troubleshooting question, please first look in the FAQ 
(http://code.google.com/p/slideshow/wiki/FAQ), search in the Google Group 
(http://groups.google.com/group/mootools-slideshow) and / or post your 
question there! This form is only for technical issues / bugs, thank you.

What steps will reproduce the problem?
1. http://texasjaycees.org/slideshow/Slideshow%202!/
2. Click the large image
3. Light box does not seem to initiate
4. Instead it opens the image itself

What is the expected output? 
I want lightbox to initiate

What do you see instead?
Just the image without lightbox effect

What version of the product are you using? On what operating system and 
browser?
using both a PC and MAC (leapard)

Please provide any additional information below.
My directory structure looks like the following:

index.html
css (folder)
js (folder)
_common (folder)
_MacOSX (folder)
lightbox (folder)
..images
..lightbox.css
..lightbox.js

Thank you!

Original issue reported on code.google.com by thadfieb...@gmail.com on 1 May 2009 at 3:10

GoogleCodeExporter commented 9 years ago
Checking out the example at:

http://texasjaycees.org/slideshow/Slideshow%202!/lightbox/

You need to initialize the script with:

Lightbox.init();

Original comment by aeron.gl...@gmail.com on 1 May 2009 at 3:21

GoogleCodeExporter commented 9 years ago
Thank you for the quick reply. Where do I add this "Lightbox.init();"?

I did not see that command in the sample

Original comment by thadfieb...@gmail.com on 1 May 2009 at 3:27

GoogleCodeExporter commented 9 years ago
You would replace the bit that starts "var box = new Lightbox..." with
"Lightbox.init();". Note that the onOpen / onClose callbacks do not exist in the
version you are using.

-- >8 --

// Here we create the Lightbox instance.
// In this case we will use the "close" and "open" callbacks to pause our show 
while
the modal window is visible.
var box = new Lightbox({ 
  'onClose': function(){ this.pause(false); }.bind(myShow), 
  'onOpen': function(){ this.pause(true); }.bind(myShow) 
});

Original comment by aeron.gl...@gmail.com on 1 May 2009 at 3:33

GoogleCodeExporter commented 9 years ago
Ok, not sure if I did this right, still not working. I replaced the bit from 
your 
last post with this. Complete inline JS code

<script type="text/javascript">     
    //<![CDATA[
      window.addEvent('domready', function(){
        var data = {
          '1.jpg': { caption: 'Volcano Asención in Ometepe, Nicaragua.' }, 
          '2.jpg': { caption: 'A Ceibu tree.' }, 
          '3.jpg': { caption: 'The view from Volcano Maderas.' }, 
          '4.jpg': { caption: 'Beer and ice cream.' }
        };
        // Note the use of "linked: true" which tells Slideshow to auto-link all 
slides to the full-size image.
        var myShow = new Slideshow('show', data, { thumbnails: true, captions: 
true, controller: true, delay: 3000, height: 300, hu: 'images/', linked: true, 
width: 400 });
        Lightbox.init();

        });
    //]]>
    </script>

Original comment by thadfieb...@gmail.com on 1 May 2009 at 3:39

GoogleCodeExporter commented 9 years ago
Sorry, just checked and the version of Lightbox you are using is only 
compatible with
mootools 1.11 - the Slideshow requires mootools 1.2... why not look for a 
version of
Lightbox also compatible with 1.2 - there are lots. Alternately you can compile 
a
version of mootools 1.2 with the compatibility module to work with older 
versions.

Original comment by aeron.gl...@gmail.com on 1 May 2009 at 3:45

GoogleCodeExporter commented 9 years ago
I downloaded lightbox from 
http://www.lokeshdhakar.com/projects/lightbox2/#download
I downloaded Mootools from http://mootools.net/download

How do I know which versions are compatible. Now the slideshow doesnt show the 
slides. I think I may have boofed it up a bit. Do you have the 2 .js files that 
are 
compatible for this?

Thanks!

Original comment by thadfieb...@gmail.com on 1 May 2009 at 3:59

GoogleCodeExporter commented 9 years ago
ok, I went to the source code on the working 
site "http://www.electricprism.com/aeron/slideshow/example2.html" and saved the 
js 
and css files they are using. the show works again, but lightbox still doesnt 
work.

Ideas? Thanks! You're almost rid of me, ha!

Original comment by thadfieb...@gmail.com on 1 May 2009 at 4:34

GoogleCodeExporter commented 9 years ago
nevermind, you are rid of me. I put the orginal code back in and magic happened!

Thank you for your help! I just had the wrong js files in there.

Enjoy your weekend!

Original comment by thadfieb...@gmail.com on 1 May 2009 at 4:41

GoogleCodeExporter commented 9 years ago
had the same problem
lightbox is not compatible with mootools
use slimbox instead of lightbox

-Jahkey

Original comment by jah...@gmail.com on 7 Jul 2010 at 11:52