Created
September 30, 2014 08:59
-
-
Save kinglozzer/29f36017232de304aaab to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Page extends SiteTree { | |
private static $db = array( | |
'ShowInFooter' => 'Boolean' | |
); | |
private static $defaults = array( | |
'ShowInFooter' => 1 | |
); | |
/** | |
* @return FieldList $fields | |
*/ | |
public function getSettingsFields() { | |
$fields = parent::getSettingsFields(); | |
$showInFooter = CheckboxField::create('ShowInFooter', 'Show in footer'); | |
$fields->insertAfter($showInFooter, 'ShowInSearch'); | |
return $fields; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment