There are four ways to create multiple columns in HTML, each with its own strengths and weaknesses.
Use tables in HTML
Element which is not used for page layout. Its purpose is to display data in tabular form. So do not use the table to create a layout for the page because it will make the code very messy. Imagine a few months later going back to editing the page design and how difficult it would be.
Framework CSS
If you want to create a fast layout, you can use frameworks like Bootstrap .
Floating characteristic (float) of CSS
Designing the entire layout of the site with floating properties (float)
in CSS is very common. Float
is easy to learn - just remember how it works. But this also has the disadvantage that it attaches to the flow of documents, which can affect the flexibility of the page. Below is an example of CSS floating properties.
The TipsMake.com Technology category will include tips, instructions for using software, hardware, fixing network errors, and fixing computer errors on many operating systems such as Windows, macOS, Linux, Android, iOS, etc. .
Keep up to date with the latest tips and tricks to troubleshoot your readers.
Results display page with the floating properties of CSS
Flexbox CSS
Flexbox is the new layout mode in CSS3.
Using flexbox ensures that the elements work as expected when the page layout must adapt to different screen sizes and devices. But this way has a disadvantage of not working on IE10 and earlier versions.
This is an example of creating a page layout with flexbox.
The TipsMake.com Technology category will include tips, instructions for using software, hardware, fixing network errors, and fixing computer errors on many operating systems such as Windows, macOS, Linux, Android, iOS, etc. .
Keep up to date with the latest tips and tricks to troubleshoot your readers.
When resizing an open HTML page, you'll see the page layout change:
Page layout with flexbox
Previous article: Head element in HTML
Lesson: Designing websites running on multiple devices (responsive web) in HTML