tags:

views:

133

answers:

3

How to centralize vertically of a div??

In FF, chrome, opera, safari, I use this:

top: 50%;

And centralize, but IE stuck at top. Why? how to centralize vertically in IE?

A: 

Best link I've found on centering content is here.

I've used it in a couple of sites and it works on all browsers.

Fermin
The downside here is that they use some browser specific hacks to get it working in all browsers, which makes it difficult to understand and maintain as a developer/web-designer.
awe
+4  A: 

Read this article and hopefully get enlightened.

Vertical Centering With CSS

It explains 5 methods to achieve vertical alignment.

Developer Art
Method 3 looked like a good simple and cross browser solution.
awe
A: 

A nice one here

Vertical Centering in CSS - Example

rahul
That one requires that height of the containing tag is set to a fixed value. IE has a problem when the container has not fixed value.
awe