css: wont margin-left when exist a float element
I have this:
htt开发者_高级运维p://jsfiddle.net/ETm93/
Now my floated element, leftPanel is having a margin-right: 20px; works fine. Now I want to give rightPanel_center a margin-left by 50px; and it do not wants to.
Why cant I do this and how should I solve it?
The margin for that element starts at the left side of the screen, not where you think it starts. If you set margin to 180px, 190px, etc. You will see that it starts to expand at that point (but probably not where you're expecting it to expand from).
Try to set float: right
at profile_rightPanel_center div
Regards!
精彩评论