Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

BUG: Setting page-break-after:always for <P> Tag Causes Infinite Pagination


View products that this article applies to.

This article was previously published under Q274554

↑ Back to the top


Symptoms

Setting the page-break-after:always value for a <P> tag in an embedded style sheet may cause infinite pagination when you view the HTML page in Print Preview.

If you try to print the HTML page, this infinite pagination causes the IEXPLORE process to take 98 to 100 percent CPU time.

↑ Back to the top


Cause

This problem occurs when you have an empty <P> tag and no space or text between the closing </P> tag and the opening <TABLE> tag.

↑ Back to the top


Resolution

To resolve this problem, use the nonbreaking space entity (&nbsp;) to add an extra space between the closing </P> tag and the opening <TABLE> tag. Or, you could replace the <P></P> tags with a single <P/> tag.

This issue is resolved for Internet Explorer 5.5 Service Pack 2 with an updated version of the file MSHTML.DLL. This file is included with the MS02-023: May 15, 2002, Cumulative Patch for Internet Explorer.

For additional information about this Cumulative Patch for Internet Explorer, click the article number below to view the article in the Microsoft Knowledge Base:
321232� MS02-023: May 15, 2002, Cumulative Patch for Internet

↑ Back to the top


Status

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

↑ Back to the top


More information

Steps to Reproduce Behavior

Create a new HTML file called Test.htm, and paste the following code:
<HTML>
<HEAD>
<TITLE>Q274554</TITLE>
<STYLE type=text/css>
 P {PAGE-BREAK-AFTER:always}
</STYLE>
</HEAD>
<BODY>
<P></P>
<TABLE WIDTH="85%" ALIGN=center BORDER=1 CELLSPACING=1 CELLPADDING=1>
	<TR>
		<TD>11</TD>
		<TD>12</TD>
	</TR>
        .       
        .
        .
        .
        .  
	<TR>
		<TD>141</TD>
		<TD>142</TD>
	</TR>
</TABLE>
</BODY>
</HTML>
				
Make sure that the table extends beyond a single page.

Note: This bug does not reproduce if the <TABLE> tag is wrapped in <P></P> tags.

↑ Back to the top


References

For more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites:

↑ Back to the top


Keywords: KB274554, kbfix, kbbug

↑ Back to the top

Article Info
Article ID : 274554
Revision : 5
Created on : 5/11/2006
Published on : 5/11/2006
Exists online : False
Views : 298