Updated the page type load handler to correctly set the page type and the pages layout