There are multiple instances of <dd>
and <dt>
elements in a specific order on this page. For instance:
<dt>
"Here is some random text"
</dt>
<dd>
<input type="text">
<span></span>
</dd>
This structure occurs frequently throughout the page. When a user attempts to print the page, I want to ensure that there are no page breaks between the <dd>
and <dt>
elements. They should always be kept together.
Is there a way to achieve this? Applying the CSS properties: page-break-after:avoid
on the <dt>
element or page-break-before:avoid
on the <dd>
element does not appear to work.
Thank you for your assistance.