template->getPageContent now become public. So you can directly get rendered content from template file.