2

There is a framework that my company wants to acquire that generates all HTML with position absolute. It has its own GUI Designer. Mainly this application will be used to design HTML forms. Is it a bad practice to have a complete HTML layout with position absolute? I am afraid that this will be a maintenance hell in the long run.

EDIT:

They claim that it is a responsive design and that it can be used across multiple devices. I'm skeptic about this.

15
  • Depends on the purpose of the projects you'll make with it. If you decide you want it to work responsively across multiple devices then yes, it will be a problem. If it's a kiosk application where all devices are exactly the same size then no, you won't have so many issues (in fact it'll probably make testing a bit easier).
    – JonW
    Dec 18, 2013 at 16:07
  • Can you provide a link to this framework?
    – Luke
    Dec 18, 2013 at 16:48
  • 1
    The question is about implementation and not UX - I suggest it to be migrated to stackoverflow, where you shall get much more informed answers.
    – Izhaki
    Dec 18, 2013 at 17:07
  • 2
    IMO I think "closed framework" is much worse than how things are positioned.
    – Luke
    Dec 18, 2013 at 17:08
  • 1
    To be fair, HOW a page is constructed DOES affect the UX. A good UX team should be cognizant of that--even if they themselves aren't the ones coding it.
    – DA01
    Dec 18, 2013 at 17:30

3 Answers 3

3

I would say that although it may not be the worst sin in the world, it is probably bad practice. One problem: If you have everything positioned absolutely and the window re-sizes, the page will probably have to run some javascript to resize the elements.

1

I use absolute positioning quite a bit as a replacement to floats (in some cases) because it works very well for me for responsive design purposes. I never position anything absolutely unless it is relative to something else.

So for example, in the header for my website, at the far left I want a logo, at the far right I want a menu button. What I do is create a div for the header, assign it relative positioning, then place my images inside the div with absolute positioning. The logo has left: 0% and menu has right: 0%. The header div adjusts its width based on the browser size, but no matter what the width, my two elements are always at opposite ends. Works great for responsive purposes, for me anyway. I'm sure there are other solutions.

Of course, this is one example. I use the same sort of technique all over the place (i.e. "relatively absolute positioning", as I call it).

0

It's impossible to say without seeing the page and its markup. There may be a reason for it but ... not likely. Some people use absolute positioning for everything because it's easier, and it may well be the best solution for whatever this is, but, as one who does this all the time, I'm questioning whether it's actually necessary. And that brings me around to the beginning of this. There is no way to know without seeing it.

Not the answer you're looking for? Browse other questions tagged or ask your own question.