Skrevet av Emne: Creating pagebreaks on HTML documents using stylesheets  (Lest 5140 ganger)

ATC

  • Gjest
Creating pagebreaks on HTML documents using stylesheets
« på: 27. ſeptember 2008, 18:24 pm »
  • [applaud]0
  • [smite]0
  • HTML documents are platform/media independent, and as such there are no native pagebreak tags. However, the problem can be solved using stylesheets.



    ATC

    • Gjest
    [Solved] Creating pagebreaks on HTML documents using stylesheets
    « Svar #1 på: 27. ſeptember 2008, 18:24 pm »
  • [applaud]0
  • [smite]0
  • Put the following code in the style sheet:
    "<STYLE>
       .pagebreak {page-break-before:always}
    </STYLE>"

    Now use the following HTML code to insert pagebreaks:
    "<DIV class='pagebreak'>&nbsp</DIV>"

    For more web specific solutions, see http://www.west-wind.com/wckb/index.htm
    Credits fly out to Waffle for this tip :-)