I have a problem with centering div in HTML (vertical & horizontal). My code looks something like this:
SOME HTML
This will center the horizontally: #container{ width: 366px; height: 274px; margin: 0 auto; } Centering vertically is not quite simple, you maybe have to use javascript for that, or you try this css solution. 0 讨论(0) 查看其它6个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复
horizontally: #container{ width: 366px; height: 274px; margin: 0 auto; } Centering vertically is not quite simple, you maybe have to use javascript for that, or you try this css solution. 0 讨论(0) 查看其它6个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复
#container{ width: 366px; height: 274px; margin: 0 auto; }
Centering vertically is not quite simple, you maybe have to use javascript for that, or you try this css solution.