rewrite page to tiles