mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
BUGFIX Moved creation of "help" menu entry from cms/_config.php to LeftAndMain::init() to get localized titles (locale isn't set at _config.php level)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/branches/2.3@68177 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
c09aed0fda
commit
f461b91eba
@ -19,11 +19,4 @@ Director::addRules(50, array(
|
||||
));
|
||||
|
||||
CMSMenu::populate_menu();
|
||||
|
||||
CMSMenu::add_link(
|
||||
'Help',
|
||||
_t('LeftAndMain.HELP', 'Help', PR_HIGH, 'Menu title'),
|
||||
'http://userhelp.silverstripe.com'
|
||||
);
|
||||
|
||||
?>
|
||||
|
@ -77,6 +77,13 @@ class LeftAndMain extends Controller {
|
||||
i18n::set_locale($member->Locale);
|
||||
}
|
||||
|
||||
// can't be done in cms/_config.php as locale is not set yet
|
||||
CMSMenu::add_link(
|
||||
'Help',
|
||||
_t('LeftAndMain.HELP', 'Help', PR_HIGH, 'Menu title'),
|
||||
'http://userhelp.silverstripe.com'
|
||||
);
|
||||
|
||||
// set reading lang
|
||||
if(Translatable::is_enabled() && !Director::is_ajax()) {
|
||||
Translatable::choose_site_lang(array_keys(i18n::get_existing_content_languages('SiteTree')));
|
||||
|
Loading…
Reference in New Issue
Block a user