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

  • SEARCH
  • Home
  • 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 7784549
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T20:06:46+00:00 2026-06-01T20:06:46+00:00

I am using the jquery .animate function to create a simple accordion, the navigation

  • 0

I am using the jquery .animate function to create a simple accordion, the navigation is in the form of tabs each containing a background image. The accordion works fine except that as it animates the tab images disappear and reappear again. Here is the link:

http://www.piersrueb.com/newsite_tabs/

Here is the js:

$(document).ready(function(){

$('.tab-1').toggle(function() {
            $('.section-1').animate({width: 800});
            $('.section-2').animate({width: 60});
      }, function() {
            $('.section-1').animate({width: 30});
      });

$('.tab-2').toggle(function() {
            $('.section-2').animate({width: 800});
            $('.section-1').animate({width: 30});
      }, function() {
            $('.section-2').animate({width: 60});
      });

});
  • 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-01T20:06:47+00:00Added an answer on June 1, 2026 at 8:06 pm

    Make a parent div of section-1 and tab-1 now on click on tab-1 animate whole parent div. do same for section-2 and tab-2.
    I think it might work. as now section and tab are animating separately that’s why it is causing delay

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

Sidebar

Related Questions

i tried to create a simple css background-image transition usind the jquery fadeIn fadeOut
I'm using this animate jQuery code: $('.tabs').hover( function(){ $('#tabs-wrap').animate({marginTop: '+=147'}, 500); $('.tabs li a').delay(250).animate({height:
I am animating the background image of a div using jQuery .animate(), but sometimes
I have the following Javascript code (using jQuery): floatUpAndDown(); function floatUpAndDown() { $(#bird).animate({top: '+=30px'},
I'm using this jQuery to hide a DIV: $(#slider).click(function() { $(.help).slideToggle(); $(#wrapper).animate({ opacity: 1.0
How can you use jQuery to create the effect of sliding a repeated background-image
All, I am trying create a 'to & fro' animation using jquery animate &
I'm using JQuery to create a Horizontal Accordion menu (based on the tutorial at
I'm trying to create a simple toggling sidebar using jquery, where it expands and
Using jQuery 1.7.2 $(function(){ $('#parentElem').mouseenter(function(){ $('.myElem').animate({opacity:1}, 'fast'); }).mouseleave(function(){ $('.myElem').stop().animate{opacity:0}, 'slow'); }); }); In this

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.