利用float进行页面布局时常常会出现父级元素没有高度的塌陷问题,如以下代码:
<!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8"> <title></title> </head> <style> .father-div{