Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mahara
mahara
Commits
b43f8c57
Commit
b43f8c57
authored
Jun 08, 2011
by
Richard Mansfield
Committed by
Gerrit Code Review
Jun 08, 2011
Browse files
Merge "Reset the site language immediately after config is loaded (bug #787123)"
parents
cd7c4687
9ca6bb55
Changes
1
Hide whitespace changes
Inline
Side-by-side
htdocs/lib/mahara.php
View file @
b43f8c57
...
...
@@ -926,7 +926,13 @@ function print_object($mixed) {
function
current_language
(
$reset
=
null
)
{
global
$USER
,
$CFG
,
$SESSION
;
static
$lang
;
static
$lang
,
$cfglang
;
if
(
!
isset
(
$cfglang
)
&&
isset
(
$CFG
->
lang
)
&&
!
empty
(
$CFG
->
lang
)
&&
is_null
(
$reset
))
{
// This is the first call to current_language after load_config, so ensure the
// language is reset.
$reset
=
$cfglang
=
$CFG
->
lang
;
}
if
(
!
empty
(
$reset
))
{
$lang
=
$reset
;
// Set the language for this request
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment