title: Page-break-inside:avoid not working
body: <p>I have a print stylesheet for my (Wordpress) site, and I want images to print on a single page rather than being split across pages. In some cases, even lines of text are being split across pages. I've included <code>img {page-break: avoid;)</code> in my print stylesheet, but no luck. I've found some previous answers but they're kind of old.</p>
  
  <p>Is there a reliable way to print a moderately-sized image on a single page rather than splitting it across pages? Why are lines of text breaking across pages?</p>
  
  <p><a href="https://i.stack.imgur.com/CJ6UZ.png" rel="noreferrer"><img src="https://i.stack.imgur.com/CJ6UZ.png" alt="picture broken across two pages"></a></p>
  
  <p><img src="https://i.stack.imgur.com/6F8q7.png" alt="lines breaking across pages"></p>
  
  <p>Site: <a href="http://74.220.217.211/housing-developments/grafton-townhomes/" rel="noreferrer">http://74.220.217.211/housing-developments/grafton-townhomes/</a></p>
  
  <p>Related posts:</p>
  
  <ul>
  <li><p><strong><a href="https://stackoverflow.com/questions/2649169/print-styles-how-to-ensure-image-doesnt-span-a-page-break">Print styles: How to ensure image doesn&#39;t span a page break</a></strong></p></li>
  <li><p><a href="https://stackoverflow.com/questions/2226939/what-are-most-useful-media-print-specfic-cross-browser-compatible-css-propert">What are most useful media=&quot;print&quot; specfic ,cross browser compatible css properties?</a></p></li>
  <li><p><a href="https://stackoverflow.com/questions/31331383/what-is-the-correct-way-to-do-the-css-to-avoid-page-breaks">What is the correct way to do the CSS to avoid page breaks?</a> </p></li>
  <li><a href="https://stackoverflow.com/questions/7706504/page-break-inside-doesnt-work-in-chrome">page-break-inside doesn&#39;t work in Chrome?</a></li>
  <li><a href="https://stackoverflow.com/questions/11432044/work-around-for-page-break-insideavoid">Work around for page-break-inside:avoid</a></li>
  </ul>