Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Create a new page type

Go to End

2 Posts   1001 Views


Community Member, 9 Posts

28 June 2010 at 9:43pm

Hi folks,

I am still stuck in creating a new Page Type. I have created a HomePage.php and saved it in mysite/code.
I have http://localhost/silverstripe/index.php/dev/build?flush=1 where I click on build, thinking this is the way to re-build the database

When I open the CMS my new php is shown in the top of the screen with the CMS navigation underneath. it looks weird, and I can not save it nor publish it. When I try to look at it in a browser it calls on the allready made template

It drives me mad as I have been stuck for days so please please please, if anyone can help me, I will appreciate it big time

Thank you very much


Community Member, 9 Posts

28 June 2010 at 9:45pm

Furthermore, I have also put in the code

* Defines the HomePage page type

class HomePage extends Page {
static $db = array(
static $has_one = array(


class HomePage_Controller extends Page_Controller {


in my php as suggested in the tutorial