21278 Posts in 5728 Topics by 2599 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 628 Views |
-
New homepage type

24 March 2009 at 6:17am
I have created a HomePage.php file in the mysite/code directory with the following code
<?php
/**
* Defines the HomePage page type
*/class HomePage extends Page {
static $db = array(
);
static $has_one = array(
);}
class HomePage_Controller extends Page_Controller {
}
?>However once I run the http://localhost/db/build?flush=1 and the database is changed I am unable to save and publish a page with the new HomePage type. When i click on the save and publish button I get "javascript Parse Error". Does anyone have any ideas?
Thanks
-
Re: New homepage type

25 March 2009 at 5:37pm
I don't see a problem with that code at all.
Are you sure your db/build/flush=1 added the correct data (lines in green)?
You could also try clearing your cache.
Aaron
| 628 Views | ||
|
Page:
1
|
Go to Top |


