Add page_num to the env so that templates can see and use it

Add page_num to the env so that templates can see and use it