diff --git a/application/controllers/auth.php b/application/controllers/auth.php
index 27b3f00..500e9f2 100644
--- a/application/controllers/auth.php
+++ b/application/controllers/auth.php
@@ -37,8 +37,8 @@ class Auth extends CI_Controller {
}
// validate form input
- $this->form_validation->set_rules('username', "Benutzername", 'required');
- $this->form_validation->set_rules('password', "Passwort", 'required');
+ $this->form_validation->set_rules('username', _('Username'), 'required');
+ $this->form_validation->set_rules('password', _('Password'), 'required');
if ($this->form_validation->run() == true) {
// check for "remember me"
@@ -77,11 +77,12 @@ class Auth extends CI_Controller {
}
// validate form input
- $this->form_validation->set_rules('username', "Username", 'required');
- $this->form_validation->set_rules('realname', "Realname", 'required');
- $this->form_validation->set_rules('email', "Email address", 'required|valid_email');
- $this->form_validation->set_rules('password', "Password", 'required|min_length[' . $this->config->item('min_password_length', 'access') . ']|max_length[' . $this->config->item('max_password_length', 'access') . ']|matches[password_confirm]');
- $this->form_validation->set_rules('password_confirm', "Password confirmation", 'required');
+ $this->form_validation->set_rules('username', _('Username'), 'required');
+ $this->form_validation->set_rules('realname', _('Real name'), 'required');
+ $this->form_validation->set_rules('lastname', _('Last name'), 'required');
+ $this->form_validation->set_rules('email', _('eMail address'), 'required|valid_email');
+ $this->form_validation->set_rules('password', _('Password'), 'required|min_length[' . $this->config->item('min_password_length', 'access') . ']|max_length[' . $this->config->item('max_password_length', 'access') . ']|matches[password_confirm]');
+ $this->form_validation->set_rules('password_confirm', _('Password confirmation'), 'required');
if ($this->form_validation->run() == true) {
$username = $this->input->post('username');
@@ -95,7 +96,7 @@ class Auth extends CI_Controller {
if ($this->form_validation->run() == true && $this->access->register($username, $password, $email, $additional_data)) {
// redirect them to the login page
- $this->session->set_flashdata('message', "Registration successful");
+ $this->session->set_flashdata('message', _('Registration successful'));
redirect('auth/register_success');
} else {
// set the flash data error message if there is one
@@ -118,7 +119,7 @@ class Auth extends CI_Controller {
}
// validate the form
- $this->form_validation->set_rules('new_password', 'New Password', 'min_length[' . $this->config->item('min_password_length', 'auth') . ']|max_length[' . $this->config->item('max_password_length', 'access') . ']|matches[new_password_confirm]');
+ $this->form_validation->set_rules('new_password', _('New password'), 'min_length[' . $this->config->item('min_password_length', 'auth') . ']|max_length[' . $this->config->item('max_password_length', 'access') . ']|matches[new_password_confirm]');
if ($this->form_validation->run() == true) {
// change password if needed
@@ -158,7 +159,7 @@ class Auth extends CI_Controller {
* Allows users to request a new password.
*/
public function forgot_password() {
- $this->form_validation->set_rules('email', 'Email Address', 'required');
+ $this->form_validation->set_rules('email', _('eMail address'), 'required');
if ($this->form_validation->run() == false) {
//setup the input
$this->data['email'] = array('name' => 'email',
diff --git a/application/controllers/jobs.php b/application/controllers/jobs.php
index 8fea1c1..aca4f77 100644
--- a/application/controllers/jobs.php
+++ b/application/controllers/jobs.php
@@ -49,13 +49,13 @@ class Jobs extends CI_Controller {
switch($progress) {
case -1:
- $progress = lang('waiting');
+ $progress = _('waiting');
break;
case -2:
- $progress = lang('failed');
+ $progress = _('failed');
break;
case 100:
- $progress = lang('done');
+ $progress = _('done');
break;
default:
$progress = $progress . "%";
diff --git a/application/controllers/projects.php b/application/controllers/projects.php
index 4b51387..cd8ef2d 100644
--- a/application/controllers/projects.php
+++ b/application/controllers/projects.php
@@ -134,7 +134,7 @@ class Projects extends CI_Controller {
$this->messages->add($projectpath, 'notice');
redirect('/projects/detail/' . $data['project_id'], 301);
} else {
- $this->messages->add('Das Projekt konnte nicht gespeichert werden.', 'error');
+ $this->messages->add(_('The project could not be created.'), 'error');
$this->load->view('project/new');
}
}
@@ -148,7 +148,7 @@ class Projects extends CI_Controller {
public function detail($prj_id) {
$project = $this->project->getById($prj_id);
if (!$project) {
- $this->messages->add('Das Projekt konnte nicht geladen werden.', 'error');
+ $this->messages->add(_('The project could not be loaded.'), 'error');
redirect('projects', 301);
}
@@ -169,7 +169,7 @@ class Projects extends CI_Controller {
public function delete($projectId) {
$this->project->delete($projectId);
$this->session->unset_userdata('active_project');
- $this->messages->add("Das Projekt wurde gelöscht.", 'notice');
+ $this->messages->add(_('The project was deleted.'), 'success');
redirect('projects');
}
diff --git a/application/controllers/settings.php b/application/controllers/settings.php
index 9348ee3..d694efa 100644
--- a/application/controllers/settings.php
+++ b/application/controllers/settings.php
@@ -41,9 +41,9 @@ class Settings extends CI_Controller {
public function index() {
$profile = $this->user->profile();
$profile_fields = array(
- array('firstname', 'Vorname', 'text'),
- array('lastname', 'Nachname', 'text'),
- array('intitution', 'Institution', 'text'),
+ array('firstname', _('First name'), 'text'),
+ array('lastname', _('Last name'), 'text'),
+ array('intitution', _('Institution'), 'text'),
);
$tpl['profile'] = $profile;
$tpl['profile_fields'] = $profile_fields;
diff --git a/application/controllers/trials.php b/application/controllers/trials.php
index af8466b..adb1e3a 100644
--- a/application/controllers/trials.php
+++ b/application/controllers/trials.php
@@ -100,7 +100,7 @@ class Trials extends CI_Controller {
redirect('/trial/detail/' . $result, 'refresh');
} else {
- $this->messages->add('Der Versuch konnte nicht gespeichert werden.', 'error');
+ $this->messages->add(_('The trial could not be created.'), 'error');
$this->load->view('trial/new', $tpl);
}
}
diff --git a/application/views/dashboard.php b/application/views/dashboard.php
index 1ec4f8c..13258f0 100644
--- a/application/views/dashboard.php
+++ b/application/views/dashboard.php
@@ -9,7 +9,7 @@
-
+
@@ -36,7 +36,7 @@