October 29, 2011 11:58 pm GMT
Original Link: http://css-tricks.com/14745-centering-in-the-unknown/
Centering in the Unknown
When it comes to centering things in web design, the more information you have about the element being centered and its parent element, the easier it is. So what if you don't know anything? It's still kinda doable.
Not too hard: Known ChildIf you know the height and width of both the element to be centered and its parent element (and those measurements won't change, i.e. not fluid width environment) one foolproof way to center the element is…
Centering in the Unknown is a post from CSS-Tricks
Original Link: http://css-tricks.com/14745-centering-in-the-unknown/
Share this article:
Tweet
View Full Article