You Can View User Feedback To This Tip
I had a need to force a page break after a certain section of a page generated by Domino. I created a style sheet and used the ID attribute in conjunction with the P tag to force the page break. Domino places a <p> at the beginning of the body tag. So you can't force the page break using only the <p> tag. So by using the ID attribute it only breaks the paragraph where I tell it to! This works with straight html as well.
Thanks to Matthew Sheranko from the lnotes-l list for the basic idea. More information can be found at: http://www.htmlhelp.com/reference/css/style-html.html
Code: Place the following code in the "HTML Head" section of your domino form:
<STYLE>
#pbb4 { page-break-before: always }
</STYLE>
And place a <P ID=pbb4> where-ever you need the forced page break on your generated form.
Here's an example in straight html:
<HTML>
<HEAD><TITLE>Dynamic Styles: Page Breaking</TITLE>
<STYLE>
#pbk1 { page-break-before: always }
</STYLE>
</HEAD>
<BODY>
<p >
1st page content
</p>
<p >
more 1st page content
</p>
<p id=pbk1>
2nd Page content
</p>
</BODY>
</HTML>
- This works for IE but doesn't function at all in Netscape. Barry Parish
This was first published in January 2001