Home > front end >  CSS small white for help
CSS small white for help

Time:09-30

Why the above three properties, a picture would be less across the row, three properties all writing, the picture is vertical row, please explain

CodePudding user response:

For d1, d2, side by side float: left separately for d1, d2, and d1, d2 should be at the same level, not package d1, d2
If in d1, d2 positioning relative to d1, d2, you need to give d2 increase top: value; Left: the value of subsidence problems may be your picture is too big, set the image size
Img {
Height: the value;
Width: value;
}

CodePudding user response:

reference 1st floor zsclin response:
if you want to d1, d2, side by side float: left separately for d1, d2, and d1, d2 should be at the same level, not package d1, d2
If in d1, d2 positioning relative to d1, d2, you need to give d2 increase top: value; Left: the value of subsidence problems may be your picture is too big, set the image size
Img {
Height: the value;
Width: value;
}

D2 is the child element d1, D2 contains two img,
I wrote above three properties, if you remove a, pictures will be vertical alignment, rather than the original horizontal alignment, moreover, if I add width to d2, pictures will be aligned, I want to know the reason,

CodePudding user response:

You give three div a different background color, debugging to see again is problem, the width of div
  • Related