fresh Silverstripe install:
* I copy the /tutorial/codePage.php to /mysite/code/HWPage.php
* edit the file to have HWPage and HWPage_Controller instead of Page etc.
* I copy /tutorial/templates/Page.ss to /mysite/templates/HWPage.php
* flush, rebuild, flush
* i log into the CMS
* create a new page of type Page
* type "Hello World" in the content-field; name of page is Helloworld1; save & publish
* create a new page of type HWPage
* type "Hello World" in the content-field; name of page is Helloworld2; save & publish
* i go to the site and see links to both pages in the menu (top level, both)
from what i did i expect both pages to be rendered identically
Helloworld1 (type: Page) looks like expected: default menu on it, default theme etc.
Helloworld2 (type: HWPage) has no menu on it, the layout is distorted (margins in top, middle and bottom do not align) and only roughly resembles the theme
since i copied the code of Page[.php .ss] to HWPage, I expected it to look alike.
I also tried to inherit HWPage from Page, instead of from SiteTree; no difference.
I did try it on two different installs/machines; result is the same.
I attached an img which displays the two pages as rendered.
Am I not getting part of the concept? What is going wrong here?
Any help welcome...
Chris