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 4014798
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T09:32:26+00:00 2026-05-20T09:32:26+00:00

I use this jQuery slide show http://css-tricks.com/moving-boxes/ in my page but the problem in

  • 0

I use this jQuery slide show http://css-tricks.com/moving-boxes/ in my page but the problem in this slide show is that until you press next button it doesn’t move to next image so is there any solution to automatically moving these images in slide show or same like this any other Thanks

The code is

$ (function(){
   $ ('#slider-two').movingBoxes ({
    startPanel: 3,    // start with this panel
    width: 600,   // overall width of movingBoxes
    panelWidth: .7,    // current panel width adjusted to 50% of overall width
    imageRatio: 16/9,  // Image ratio set to 16:9
    buildNav: true, // if true, navigation links will be added
    navFormatter: function (index, panel){ return panel.find ('h2 span').text(); }, // function which gets nav text from span inside the panel header
   });

   // Example of how to move the panel from outside the plugin, only works on first selector (Use ID instead of class to target other movingboxes).
   // Get: var currentPanel = $ ('.slider').data ('movingBoxes').currentPanel(); // returns # of currently selected/enlarged panel
   // set: var currentPanel = $ ('.slider').data ('movingBoxes').currentPanel (2); // scrolls to 2nd panel & returns 2.

   // Set up demo external navigation links
   var I, t = ', len = $ ('#slider-one .panel').length + 1;
   for ( I=1; I<len; I+){
    t += '<a href="#" rel="' + I + '">' + I + '</a> ';
   }
   $ ('.dlinks')
    .find ('span').html (t).end()
    .find ('a').click (function(){
     $ ('#slider-one').data ('movingBoxes').currentPanel ( $ (this).attr ('rel'));
     return false;
    });

   // Report events to firebug console
   $ ('.slider').bind ('initialized initChange beforeAnimation completed',function (e, slider, tar){
    // show object ID + event in the firebug console
    if (window.console & window.console.firebug){
     var txt = slider.$el[0].id + ': ' + e.type + ', now on panel #' + slider.curPanel
     txt += (typeof (tar) == 'undefined')? ': ', Targeted panel is ' + tar;
     console.debug ( txt);
    }
   });

  });
  • 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-05-20T09:32:26+00:00Added an answer on May 20, 2026 at 9:32 am

    For information, a complete readme with all the options can be viewed here : https://github.com/chriscoyier/MovingBoxes

    Code modification

    Try to replace the slider initialization with this code :

    $('#slider-two').movingBoxes({
        startPanel  : 3,     // start with this panel
        completed: function() {  //function runs after slider completes movement
               setTimeout(function() {
                    $("#slider-two").data('movingBoxes').goForward();  // move to next slide.
               }, 5000); // execute the given function after 5 seconds
    
        },
        wrap        : true,  // restart the slideshow after the end
        width       : 600,   // overall width of movingBoxes
        panelWidth  : .7,    // current panel width adjusted to 50% of overall width
        imageRatio  : 16/9,  // Image ratio set to 16:9
        buildNav    : true, // if true, navigation links will be added
        navFormatter: function(index, panel){ return panel.find('h2 span').text(); }, // function which gets nav text from span inside the panel header
     });
    

    The important lines are the one with the ‘completed’ option. The add a callback called every time a new slide is shown in order to change in the next 5 seconds.

    I also added wrap : true to activate wrapping, this means the slideshow will restart at the beginning when it reaches end.

    Now you must start the slideshow somehow, so you can add this code just before the final } (last line of your pasted code) :

    $("#slider-two").data('movingBoxes').goForward();  // move to next slide.
    

    I hope this is right. Have fun !

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

Sidebar

Related Questions

I already started this in javascript so I don't want to use jquery but
I want to use this pure HTML/CSS template for my ASP.NET website: http://sub3.tanguay.de I
I'm trying to use the jQuery Cycle plugin (http://jquery.malsup.com/cycle/) to rotate testimonials located within
here is the site : http://www.notrepanorama.com at the bottom left, i use a jquery
I am trying to use JQuery in my ASP.Net 2.0 website in this scenario:
I'm trying to use this layout with two 50% column width instead. But it
I am trying to use this in my page class. I only just started
I'm trying to use Nivo's banner slider plugin ( http://nivo.dev7studios.com/ ) and Kwick's plugin
I use this tool called Lazy C++ which breaks a single C++ .lzz file
I use this line in my .htaccess file to automatically add a trailing slash

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.