I get an error when i try to do this:
Parse error: syntax error, unexpected T_PROTECTED in /home/admin/domains/silverstripe.ilink2.nl/public_html/mysite/code/Page.php on line 21
This is my PHP code:
<?php
class Page extends SiteTree {
static $db = array(
);
static $has_one = array(
);
}
class Page_Controller extends ContentController {
function init() {
parent::init();
Requirements::themedCSS("layout");
Requirements::themedCSS("typography");
Requirements::themedCSS("form");
}
}
// Group names that have publishing permissions (only groups listed here can publish/unpublish)
protected $publisherGroups = array(
"Administrators"
);
function canPublish() {
$member = Member::currentUser();
return $member->inGroups($this->publisherGroups);
}
?>