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

The Archive Base Latest Questions

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

i got a click thats triggers a slideDown() on a div. my thought is

  • 0

i got a click thats triggers a slideDown() on a div. my thought is that after the div is expanded i set the height of another div based on the expanded div. The problem becomes that it takes the height and sets it before the other div is slided fully, for a fact it takes the height of the div that it got before it slide out.

is there a way to pause everything until the slideDown() is done?

$div.slideDown();

//sets the height of the Container
$outer_container.css("height", $inner_container.outerHeight());
  • 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-26T09:32:26+00:00Added an answer on May 26, 2026 at 9:32 am

    Use the callback function, which only runs once the animation is complete:

    $div.slideDown(400, function() {
        //sets the height of the Container
        $outer_container.css("height", $inner_container.outerHeight());
    });
    

    Or, to use a slightly more compact apprach:

    $div.slideDown(400, function() {
        $outer_container.height($inner_container.outerHeight());
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ive got a div thats hidden with .hide and on click opens using .show(slide,
Ive got a div that i want to slide out on click using .show(slide,
I've got a div that I am appending to the page dynamically on click
I've got a div that I want to enable a click function on, but
I've got a webpage that I'm working on where you click on a letter
I got a red square (DIV) and everytime I click on it I like
I've got a set of parametrized builds in Jenkins that to build I have
I got another question that would go to category Java noobs This time my
I got following problem: I generate a div with jQuery-Load links. Theese links inside
I've got a Jquery function that I wrote which blacks out the screen after

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.