Cakephp, JQuery JCarousel Lite, Error

Posted by ion on Stack Overflow See other posts from Stack Overflow or by ion
Published on 2010-03-28T00:27:28Z Indexed on 2010/03/28 0:33 UTC
Read the original article Hit count: 837

Filed under:
|
|
|

I am using the following code to make an unordered list into a carousel with jcarousel lite and jquery:

<?php echo $this->Html->script(array('jquery-1.4.2.min','jquery.easing.1.1','jcarousellite_1.0.1.pack','jquery.mousewheel.min'), array('inline' => false)); ?>

    <?php echo $this->Html->scriptStart(array('inline' => false)); ?>
        $(document).ready(function() {
            $(".mouseWheelButtons .jCarouselLite").jCarouselLite({
                btnNext: ".mouseWheelButtons .next",
                btnPrev: ".mouseWheelButtons .prev",
                mouseWheel: true,
                circular: false,
                start: 0,
                visible: 5,
                easing: "easein"
            });
        });
    <?php echo $this->Html->scriptEnd(); ?>

However I'm getting the following javascript error in firebug:

a[0] is undefined

Does anyone know what is causing the error.
I am using the packed version of jcarousel lite.

The thing is that the code worked in cakephp 1.2 but now i'm using 1.3 and I have updated the syntax using scriptstart, scriptEnd and Html->script.

© Stack Overflow or respective owner

Related posts about cakephp

Related posts about JavaScript