

- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Specify width for the columns with CSS
Use the column-width property to specify the width of the columns. You can try to run the following code to implement the column-width property −
Example
<!DOCTYPE html> <html> <head> <style> .demo { column-count: 4; column-rule-color: gray; column-rule-style: dashed; column-width: 100px; } </style> </head> <body> <div class = "demo"> This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. </div> </body> </html>
- Related Questions & Answers
- Specify the gap between the columns with CSS
- Set the width of the rule between columns with CSS
- Specify the background image with CSS
- Specify the number of columns in a CSS grid layout
- How to specify the number of columns an element should be divided into with CSS
- Set the border image width with CSS
- Specify position of the background images with CSS
- Specify the size of the background images with CSS
- Specify the speed curve of the animation with CSS
- Set border width with CSS
- Set the width of the outline with CSS
- Specify the left padding of an element with CSS
- Specify the bottom padding of an element with CSS
- Specify the top padding of an element with CSS
- Specify the right padding of an element with CSS
Advertisements