Missing div borders
I need your help,
It seems that I am having some difficulty with attempting to add a div around a textarea inside a container div as well as a border for the div encompassing my button at the bottom of the container div.
First problem: the right side border is missing
Second problem, the 1px solid red is missing from the inner2 div.
Here is a pic of the problem and the desired result:
Desired result is:
Here is the HTML & CSS in question:
It’s because the
textarea element has default padding. Since padding isn’t included in an element’s width/height calculations, it overflows outside of the parent element because a width of
100% + the border is greater than the parent elements width.
You could either remove this padding, or include the padding in the dimension calculations by adding
box-sizing: border-box to the