Each week I feature one of my answers on stackoverflow hoping it might help other people.
This weeks question by Junaid Abe Miessler: Is it possible to have auto margins when you have position:absolute?
I’m having an issue where a div is not butting up to the very top of the page. I tried to solve this by adding
which put it at the top like I wanted but it also went to the left of the page. I want it to be centered in the page which works if I use auto left and right margins without position:absolute.
Is there any way to have auto margins AND position it at the very top of the page?
I think you have to set left and right (or maybe only left) to 50%