Grow your CSS skills. Land your dream job.

jquery error “Object .sliderImage has no method ‘apply’ “

  • # June 14, 2013 at 4:54 am

    i have image slider code which was not working on android tablet . but after adding following line it started working on android also.

    $(‘#myImageFlow ‘).on(“click touchstart”,”.sliderImage”,touchStart());
    function touchStart(event){
    };
    but this is giving Error::

    Uncaught TypeError: Object .sliderImage has no method ‘apply’,
    touchstart() i don’t need but , instead of that if i am giving false then my slider is not working on android.

    # June 14, 2013 at 5:46 am

    Try

    $(‘#myImageFlow ‘).on(“click touchstart”,”.sliderImage”,touchStart);

    you want to give a reference to the function as parameter, what you’re doing with parentheses `touchStart()` is running the function and giving the return value as parameter.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".