- This topic is empty.
Viewing 7 posts - 1 through 7 (of 7 total)
Viewing 7 posts - 1 through 7 (of 7 total)
- The forum ‘CSS’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Hi
I created a web page, but the main content tag does not get as large as it’s childs
Therefore, the footer tag falls under the main content tag
what do i should do for Solve this problem
I would start with reproducing the issue in Codepen.io.
Just the minimal amount of code to show the problem NOT the entire codebase.
A vague description of a problem helps no-one.
Generally speaking, an element’s height should expand to fit the content, unless you have explicit heights defined in the CSS that are restricting expansion, OR child elements are taken out of the document flow (e.g. absolute positioning) so that they are not “seen” by the parent.
We can’t really offer any specific help without seeing the code upfront though. Please provide a reduced demo in CodePen to show us the undesirable behaviour. Note that we don’t need your whole codebase – just the HTML and CSS relevant to the immediate issue.
i uploaded my file: https://ufile.io/ozzeq
please search “this” in style tag for comfort
Thanks a lot.
A CodePen is preferred – it’s easier for us to troubleshoot in.
Try add float: right; on #footer
cheers
oh. my problem is solved
Thanks a lot again.