23 January 2009 at 3:55am
Well, if you would not add them to your home page template, but to the Page.php code, they extend to whatever page that extends from Page.php (inheritance). But then, these fields show up on every template (in the CMS) which means that whatever you enter in those fields is unique for that particular instance. Did you mean that you want to have fields that are truly global, in other words you edit them in one place but they show up on every page?
23 January 2009 at 4:40am
(Last edited: 23 January 2009 4:41am),
ok so you basically want a footer on your site which is editable in the admin right?
So what you want to do is create a 'FooterPage' page type which will then hold all you footer variables in the same way that you would create a static sidebar. This thread shows you how to do that: http://www.silverstripe.org/customising-the-cms/show/252007
You really want to have one place to edit your footer rather than having the fields on every page. Then you can just have a function GetFooter() in your Page_controller and return the FooterPage type so that you can use it in the templates