MINOR Warning about install.php existing for root site tree node as well (SiteConfig form)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@110440 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sean Harvey 2010-09-05 02:48:30 +00:00 committed by Sam Minnee
parent 2a708d9afa
commit d566ac4292

View File

@ -95,6 +95,14 @@ class SiteConfig extends DataObject implements PermissionProvider {
$fields->makeFieldReadonly($taglineField);
$fields->makeFieldReadonly($titleField);
}
if(file_exists(BASE_PATH . '/install.php')) {
$fields->addFieldToTab("Root.Main", new LiteralField("InstallWarningHeader",
"<p class=\"message warning\">" . _t("SiteTree.REMOVE_INSTALL_WARNING",
"Warning: You should remove install.php from this SilverStripe install for security reasons.")
. "</p>"), "Title");
}
$tabMain->setTitle(_t('SiteConfig.TABMAIN', "Main"));
$tabAccess->setTitle(_t('SiteConfig.TABACCESS', "Access"));
$this->extend('updateCMSFields', $fields);