In the PDF output the content of the following div tag spills over into the footer at the bottom of the page:
<div class="Example">
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
<p>Words words.</p>
</div>
How can I stop it spilling into the footer? This is what's in the CSS for the print media:
div.Tip,
div.Example
{
display: block;
background-repeat: no-repeat;
background-position: left top;
height: 10mm;
padding-bottom: 1.7rem;
padding-left: 60px;
padding-top: 0.1rem;
}
div.Tip
{
background-image: url('../Images/Icons/Icon_Tip.png');
}
div.Example
{
background-image: url('../Images/Icons/Icon_Exam.png');
}
I tried using "page-break-inside: avoid" for the div which helps because it forces a page break before the div. But some of our examples are longer than a page long, and I stll see the content spilling into the footer.
Content within a div spills into the footer in the PDF book
-
- Jr. Propeller Head
- Posts: 4
- Joined: Wed Jan 04, 2017 4:28 am
Re: Content within a div spills into the footer in the PDF b
HI Judy,
Not sure if you still need a reply to this one, but have you tried:
- setting page-break-inside to auto
- removing the height setting?
I have divs that are sometimes several pages long and this seems to work for me.
Not sure if you still need a reply to this one, but have you tried:
- setting page-break-inside to auto
- removing the height setting?
I have divs that are sometimes several pages long and this seems to work for me.
Good luck and good writing!
TWAnnie
TWAnnie