I have created a new page type called HomePage. To do this I have created a Homepage.php file which is located at mysite/code/HomePage.php and I have a file called HomePage.ss located at template/Homepage.ss. I have run dev/build?flush=1 and ?flush=all and I have a file in site root called silverstripe-cache at SilverStripe/silverstripe-cache set to read / write and again run dev/build?flush=1 and ?flush=all.
when I go to the admin panel i can see the option Change to HomePage in the page type drop down menu. It allows me to select this option but when I save it changes the page type to Change to Error Page and then saves it as that page type.
This then returns the statement "Generated with the default ContentController.ss template" on the site for that page but all other pages are ok.
Can anyone tell me where I have gone wrong?