I want to set a fixed width to a parent element and I want to put long text in it. but when text's length get bigger than it's parent 's width, it just exceeds it's parent's width, not to move to the next row.
So what i want to do is to make a flexible box that keeps it's context in its fixed width length ( of course the height of the box can change depending on the number of rows. )
Here is a simple code.
<style type="text/css">
.wrap {position:relative; width:500px; border:1px solid red;}
.child {width:50%; padding:5px; border:1px solid blue;}
</style>
<div class="wrap">
<div class="child">aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</div>
</div>