PDA

View Full Version : Father Div and son div



WebGirl
15 Dec 2010, 12:25 PM
Div father does not take the contents of the div daughter to where she goes. If I center the parent div, the div daughter does not obey.
Well folks, this is exactly what is happening ... I have the CSS code that generates a div with a class picture in your background.

What I want is to place text, images or scripts inside that div in css scheduled. This div is set in the css to have a background image. Therefore if I put a text, anything, it's as if I had put such a dialogue in a speech bubble. You know those cartoons where the characters speak in balġezinhos? Well that's exactly what I want to do. The parent div is the background of speech bubble, and I want to put text inside that div father. The texts in turn, as will be inside the parent div, so will their children divs.

What happens is that when centralize div balloonvine (father), the text that was within him is not going to where the father was div. That is not centralized.

What I do like to get the child div (text) follow the same position of the parent div? (speech bubble)?

---------------- This is the CSS code that I'm putting ----------------

<! - image of balloon ->
<style type='text/css'>
. balao {
background-image: url (balao.jpeg);
background-position: center;
background-repeat: no-repeat;
height: 210px;
width: 265;
padding: 45 55 10-50px;
}
</ style>
<! - image of balloon ->


-------------- This is the HTML code that I'm putting: --------------

<div class="balao">
Hello I am the text (son) and I'm inside the div (father) balao.jpeg
</ div>

Ps: In this case I took the styling of the div daughter and put the plain text, still did not work ...