Adding Line Breaks for Printed Media

CSS gives us a nice way to insert line breaks into HTML with page-break-before and page-break-after.

Here's a pretty self explanitory example below. Looks normal in the browser, but when you print the HTML, line breaks are there.

<html>
<head></head>
<body>
This is the first page
<br style="page-break-before:always;">
This is the second page
<br style="page-break-after:always;">
This is the last page
</body>
</html>

Comments (Comment Moderation is enabled. Your comment will not appear until approved.)

Psykel blog uses BlogCFC (by Raymond Camden). Layout design inspired by arcsin