views:

26

answers:

1

Hello, I'm looking to align one of my <div> containers which has a nested <form ype="text"> and 2 <span> tags but I can't seem to apply a margin-top: 6px; to the container <div>.

Would padding-top: 6px; be the answer?

+2  A: 

Here ya go, http://jsfiddle.net/EWkMA/

CSS:

div#middle {
    height: 200px;
    vertical-align: middle;
    display: table-cell;
}

HTML:

<div id='middle'>
    <input type='text' value='test'/><br/>
    <span>a</span><br/>
    <span>two</span>
</div>
Robert
Thanks, perfect!
BOSS