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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T07:53:44+00:00 2026-06-09T07:53:44+00:00

I have to work on a software that generates tables (sort of…) and which

  • 0

I have to work on a software that generates tables (sort of…) and which must provide total control over the position of elements.

So far, we had constructs like this:

<div id="container" style="display: table-row">
  <div id="a" style="position: absolute"></div>
  <div id="b" style="position: absolute"></div>
  <div id="c" style="position: absolute"></div>
</div>

And some javascript code to place the #a, #b and #c elements within #container using left and top style directives.

That way, the elements could even be “inverted”, that is: #b could be the first element on the left and #a the last, depending on some other rule.

However, this fails because those are taken out of the flow and so #container has a null height. Fair enough.

It seems impossible to solve this problem that way, so I thought of using position: relative for the child elements, but doing so, the left and top style directives now refer to the initial element’s position and are no more usable…

Have you ever had to deal with a similar situation ? What can I do to achieve the desired behavior ?

Thank you very much.

P.S : For those who wonder why we don’t use <table> elements to represent a table, lets just say I wonder as well but have no power over that decision…

  • 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-09T07:53:46+00:00Added an answer on June 9, 2026 at 7:53 am

    Two things come to mind – both hacky and probably not super scalable:

    1) Add position: absolute not in the CSS but in the JS – but before you do, fix the container to its pre-absolute, offset dimensions, so the height isn’t lost

    var container = $('#container');
    container.height(container.height()).children().css('position', 'absolute');
    

    2) Go with position: relative, but set their new positions relative to their original positions minus their offset.

    var el = $('#some_el');
    el.css({top: 0 - el.position().top});
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an application that is going to work like a p2p-software where all
I have an assembly which generates a Form (it is a client-software). I can
In the software development environment where I work we have a group of developers
In software companies I have seen it's really hard to work on very large
I have to work on a database in which there are many stored-procedures &
I have a work page that shows all projects. I am using a taxonomy
Our software produces a lot of data that is georeferenced and recorded over time.
I work for a software development company and we have around 100 people working
As you work in a legacy codebase what will have the greatest impact over
We have a large high-performance software system which consists of multiple interacting Java processes

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.