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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T21:56:23+00:00 2026-05-27T21:56:23+00:00

I am looking for some way to click on an image or link on

  • 0

I am looking for some way to click on an image or link on a Div and it will slide to another div without changing to height…so something like the below

<div id="div1">
<img src="image.jpg" onclick="slide_to_other_div" />
</div>

<div id="div2" style="display:none">
<p>Another Div Here</p>
</div>

But I don’t want an accordion effect… I want to slide to Div2 without affecting the height?

Explained further …

Suppose you have a table>

<table>
<tr>
  <td id="div1"><a href="#div2">Slide to Div2 Direction --> </a></td>
  <td> id="div2" style="display:none">This is Div 2</td>
</tr>
</table>

So, Div1 scrolls sideways to Div2 when I click on the link to Div2

  • 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-27T21:56:23+00:00Added an answer on May 27, 2026 at 9:56 pm

    I’m not entirely sure I know what you want to have happen, but here are a series of steps which might accomplish your goal?

    1. Calculate the current image height and explicitly set it so that it won’t change.
    2. Calculate the current absolute image position
    3. Calculate the absolute div2 position
    4. Detatch the image from div1, set it’s style to be position absolute with the absolute position calculated earlier, and attach it to body
    5. Animate the top and left properties of the position so it “slides” to the new location
    6. Detatch the image from body, remove absolute positioning values, attach it to div2, and show div2

    Does that sound like what you are looking for? Each of those steps can be accomplished via jquery.


    EDIT: Now that I think I’m understanding you more, you are probably looking for a horizontal accordian. You could code this from scratch, but I would suggest looking at existing solutions to guide you (or to simply use). Here is an example of one. Google “horizontal accordian” to find more if that doesn’t suit your fancy.

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

Sidebar

Related Questions

Im looking for a way to change the background image of a div using
I'm looking for a package the browser's back button for dired. i.e. some way
Looking for some advice on the best way to implement localization along with client
I'm looking for some advice on the best way to provide a single place
I spent some time looking for a way of resolving my issue but with
I am looking for a way to define some syntax coloring for a language
I'm looking for a way to use some variant of vsnprintf() with a buffer
I am looking for a way to remove some characters from the end of
I'm looking for a way to cheat and create some very rough translations of
I'm looking for a way to automatically do some clean up tasks when the

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.