Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9166747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T15:13:24+00:00 2026-06-17T15:13:24+00:00

I have a jquery image scroller which when reaches the last <li> appends the

  • 0

I have a jquery image scroller which when reaches the last <li> appends the first <li> and so on. But when i am using hover instead of onclick it not working below is the code

  jQuery("#gallery-next").click(function () {
     next_scroll();
 });

 function next_scroll() {
     if (jQuery("#gallery").position().left > stopPosition && !jQuery("#gallery").is(":animated")) {
         jQuery("#gallery").animate({
             left: "-=" + imageWidth + "px"
         });
     }
     if (jQuery("#gallery").position().left == stopPosition) {
         $("#gallery > li:first").appendTo("#gallery").fadeIn('slow');
         return false;
     }
 }

What should I do to make the mouseenter/hover work instead of click function. I have seen other solutions on this forum which is quite similar, but I am not able to utilize those. So please answer with a code. That will be much helpful.
Here is a link to check Fiddle
Thanks in advance

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T15:13:25+00:00Added an answer on June 17, 2026 at 3:13 pm

    If I understand the question, what you need is to change this:

    jQuery("#gallery-next").click(function () {
        next_scroll();
    });
    

    for this one:

    var timer = 0;
    jQuery("#gallery-next").
    mouseover(function () {
         //Call next_scroll() every two seconds
         timer = setInterval(next_scroll, 2000);})
    .mouseout(function(){
         timer = clearInterval(timer);
    });
    

    Update: Is setInterval() not setTimeOut(), sorry about the confusion, check updated fiddle

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have put together an image scroller using jquery, like this function rotateImages(whichHolder, start)
I have jQuery hover function which a transparent image will animate up. The following
I have a image which has an mouseover jquery function: $(document).ready(function ()) { mouseenter:
I have implemented the image upload code using jquery php in my php web
I'm using a plugin called jQuery image map emulator which takes parameters like so:
Anyone have a good jquery Image Preview plugin. Been looking but havent found anything
Why is this jquery image watermarking plugin not working? I am using the code
I have one scrolling image which is in jQuery, it scrolls and logos of
First off, I don't have any knowledge about java/jquery/ajax or such, but I think
I have been trying to use Jquery Image maphilight plugin but can't becoz I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.