In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article is about how to set the height and width of cells in CSS. Xiaobian thinks it is quite practical, so share it with everyone for reference. Let's follow Xiaobian and have a look.
Methods for setting height and width adaptation of cells: 1. Add "width: width value %;" style to cell elements to make the width of cell elements adaptive;2. Add "height: height value vw;" style to elements to make the height of cell elements adaptive.
Operating environment of this tutorial: Windows 7 system, CSS3 && HTML5 version, Dell G3 computer.
In css, since height is not fixed, it cannot be used directly. So the transformation idea uses width values to implement square height assignments. So theoretically, any method that can apply the width attribute to the height attribute will work.
So we can use vw units, 1 vw is equivalent to 1% of the page width, such as page width is 1000px, then 1vw is 10px.
Specific examples are as follows:
Document .shiying{ width: 30%; height: 30vw;} Month Savings January $100
Output:
Thank you for reading! About "css how to set the height and width of the cell adaptive" This article is shared here, I hope the above content can be of some help to everyone, so that everyone can learn more knowledge, if you think the article is good, you can share it to let more people see it!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.