css - How to set div to fill in remaining place taken by the dynamically sized element -
I have this code:
& lt; Div id = "body" style = "height: 295 px, width: 427px; condition: full; top: 261px; left: 284px;" & gt; & Lt; Div id = "header" & gt; Some dynamic text & lt; Br / & gt; Some dynamic text & lt; Br / & gt; & Lt; / Div & gt; & Lt; Div id = "content" & gt; & Lt; Textarea id = "text" style = "width: 100%" & gt; & Lt; / Text field & gt; & Lt; Input type = "file" style = "width: 100%" & gt; & Lt; / Div & gt; & Lt; Div & gt; & Lt; / Div & gt; I want to set the content div to fill the rest of my parents. The text is created on the server side and it changes the height of the header.
The output should look like this: The file should be at the bottom of the input content to fill the rest of the content together. The material fills the balance itself, which is influenced by the speed dynamic text.
I am only interested in CSS solutions because it is easy to do with JS. Apart from this, only the width and height of the body can be hardcodes.
Edit: Some explanation:
-
Body is fixed size
-
Header is dynamic shape, anyone It can also be of height. If its height> # body.height, the rest will be deducted and #content height will be 0. If possible, #Headers # may be limited to the rest of Beed, the rest crop or scroll.
-
Content does not require any special explanation, it contains fixed file input and mobility height textarea
Thx.
Here is a test page showing html in question:
ive has the freedom to add colorful boundaries to see what's happening.
Edit: Now there is a solution in the link above it looks a bit strange in Firefox, look sick if I can fix it
Edit 2: The final solution can be seen in the above link (tell me if I forget my imagination)
#text, # Content {height: 86%; }
Comments
Post a Comment