.parent { background: green; width: 300px; height: 150px; display: block; position:absulate; } .child { background: red; width: 150px; height: 75px; display: block; margin-top: 200px /* I want to give mergin only for child. And for this margin the chld box will go outsite of the parent box. But Its doesn't working! */ }
<div class="parent"> <div class="child"> Move this div </div> </div>
position:absulate;
absolute
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)