aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--actions/admin/site/update_basic.php4
-rw-r--r--actions/systemsettings/install.php4
-rw-r--r--engine/lib/configuration.php2
-rw-r--r--languages/en.php3
-rw-r--r--views/default/settings/system.php2
5 files changed, 11 insertions, 4 deletions
diff --git a/actions/admin/site/update_basic.php b/actions/admin/site/update_basic.php
index 4ad80ca96..25500067a 100644
--- a/actions/admin/site/update_basic.php
+++ b/actions/admin/site/update_basic.php
@@ -27,7 +27,9 @@
$site->url = get_input('wwwroot');
datalist_set('path',get_input('path'));
- datalist_set('dataroot',get_input('dataroot'));
+ datalist_set('dataroot',get_input('dataroot'));
+
+ set_config('language', get_input('language'), $site->getGUID());
system_message(elgg_echo("admin:configuration:success"));
diff --git a/actions/systemsettings/install.php b/actions/systemsettings/install.php
index b56a86f6c..06a40e167 100644
--- a/actions/systemsettings/install.php
+++ b/actions/systemsettings/install.php
@@ -31,7 +31,9 @@
datalist_set('path',get_input('path'));
datalist_set('dataroot',get_input('dataroot'));
- datalist_set('default_site',$site->getGUID());
+ datalist_set('default_site',$site->getGUID());
+
+ set_config('language', get_input('language'), $site->getGUID());
system_message(elgg_echo("installation:configuration:success"));
diff --git a/engine/lib/configuration.php b/engine/lib/configuration.php
index 48eeeebfc..acb651170 100644
--- a/engine/lib/configuration.php
+++ b/engine/lib/configuration.php
@@ -129,6 +129,8 @@
if (empty($CONFIG->sitename))
$CONFIG->sitename = "New Elgg site";
+ if (empty($CONFIG->language))
+ $CONFIG->language = "en";
}
diff --git a/languages/en.php b/languages/en.php
index 20642374b..12d4d8c2f 100644
--- a/languages/en.php
+++ b/languages/en.php
@@ -348,7 +348,8 @@ Alternatively, you can enter your database settings below and we will try and do
'sitename' => "The name of your site (eg \"My social networking site\"):",
'wwwroot' => "The site URL, followed by a trailing slash:",
'path' => "The full path to your site root on your disk, followed by a trailing slash:",
- 'dataroot' => "The full path to the directory where uploaded files will be stored, followed by a trailing slash:",
+ 'dataroot' => "The full path to the directory where uploaded files will be stored, followed by a trailing slash:",
+ 'language' => "Please enter the default language code for your site, e.g. 'en' for English, 'fr' for French, 'ru' for Russian:",
/**
* Welcome
diff --git a/views/default/settings/system.php b/views/default/settings/system.php
index 5f4e36f1e..ba3e614ee 100644
--- a/views/default/settings/system.php
+++ b/views/default/settings/system.php
@@ -27,7 +27,7 @@
<?php
- foreach(array('sitename','wwwroot','path','dataroot') as $field) {
+ foreach(array('sitename','wwwroot','path','dataroot', 'language') as $field) {
?>
<p>