Style Object
The widows property sets or returns the minimum number of lines for an element that must be visible at the top of a page (for printing or print preview).
The widows property only affects block-level elements.
Tip: widows:5 means that at least 5 lines must be visible below the page break.
Tip: See the orphans property to set or return the minimum number of lines for an element that must be visible at the bottom of a page.
Set the widows property:
Return the widows property:
| Value | Description |
|---|---|
| number | An integer that specifies the minimum number of visible lines. The default value is 2 |
| inherit | The value of the widows property is inherited from parent element |
![]()
The widows property is only supported in Opera.
Change the widows and check print or print preview:
Style Object
| WEB HOSTING |
|---|
| Best Web Hosting |
| PHP MySQL Hosting |
| Best Hosting Coupons |
| UK Reseller Hosting |
| Cloud Hosting |
| Top Web Hosting |
| $3.98 Unlimited Hosting |
| Premium Website Design |
| WEB BUILDING |
|---|
| XML Editor - Free Trial! |
| FREE Website BUILDER |
| Best Website Templates Top CSS Templates |
| CREATE HTML Websites |
| EASY WEBSITE BUILDER |
| W3SCHOOLS EXAMS |
|---|
|
Get Certified in: HTML, CSS, JavaScript, XML, PHP, and ASP |
| W3SCHOOLS BOOKS |
|---|
|
New Books: HTML, CSS JavaScript, and Ajax |
| STATISTICS |
|---|
|
Browser Statistics Browser OS Browser Display |
| SHARE THIS PAGE |
|---|