ok, just to let you all know you need css to do this.
div{
page-break-after : always;
}
echo "<div>";
{code here}
echo "</div>";
There is a problem with IE printing an extra page at the end where firefox does'nt. I am trying to find a way round this atm.