diff options
author | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-03-10 20:51:02 +0000 |
---|---|---|
committer | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-03-10 20:51:02 +0000 |
commit | 02d65694d32f42a42f4cca989be7ff231e868522 (patch) | |
tree | 59ef60147d26f6d175cfd996254144c78cb19f5f | |
parent | 042c524bab3ab401c99ed40c0df1641201f16f07 (diff) | |
download | elgg-02d65694d32f42a42f4cca989be7ff231e868522.tar.gz elgg-02d65694d32f42a42f4cca989be7ff231e868522.tar.bz2 |
More language integration
git-svn-id: https://code.elgg.org/elgg/trunk@148 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r-- | actions/login.php | 2 | ||||
-rw-r--r-- | actions/logout.php | 2 | ||||
-rw-r--r-- | engine/lib/languages.php | 7 | ||||
-rw-r--r-- | languages/en.php | 33 | ||||
-rw-r--r-- | views/default/login.php | 6 | ||||
-rw-r--r-- | views/default/navigation/topmenu.php | 8 | ||||
-rw-r--r-- | views/default/page_elements/footer.php | 2 | ||||
-rw-r--r-- | views/default/welcome.php | 2 |
8 files changed, 44 insertions, 18 deletions
diff --git a/actions/login.php b/actions/login.php index 7323f1d4d..dbc84bab5 100644 --- a/actions/login.php +++ b/actions/login.php @@ -25,7 +25,7 @@ // Set the system_message as appropriate
if ($result) {
- system_message(elgg_echo('login'));
+ system_message(elgg_echo('loginok'));
} else {
system_message(elgg_echo('loginerror'));
}
diff --git a/actions/logout.php b/actions/logout.php index 273e8be48..99ef5abf6 100644 --- a/actions/logout.php +++ b/actions/logout.php @@ -17,7 +17,7 @@ // Set the system_message as appropriate
if ($result) {
- system_message(elgg_echo('logout'));
+ system_message(elgg_echo('logoutok'));
} else {
system_message(elgg_echo('logouterror'));
}
diff --git a/engine/lib/languages.php b/engine/lib/languages.php index 3161932fd..f5abaaaa9 100644 --- a/engine/lib/languages.php +++ b/engine/lib/languages.php @@ -31,9 +31,9 @@ if (!isset($CONFIG->translations))
$CONFIG->translations = array();
- $country_code = strtlower($country_code);
+ $country_code = strtolower($country_code);
$country_code = trim($country_code);
- if (is_array($language_array) && sizoef($language_array) > 0 && $country_code != "") {
+ if (is_array($language_array) && sizeof($language_array) > 0 && $country_code != "") {
if (!isset($CONFIG->translations[$country_code])) {
$CONFIG->translations[$country_code] = $language_array;
@@ -84,9 +84,8 @@ if ($handle = opendir($CONFIG->path . "languages/")) {
while ($language = readdir($handle)) {
if (!in_array($language,array('.','..','.svn','CVS')) && !is_dir($CONFIG->path . "/languages/" . $language)) {
- //@include($CONFIG->path . "languages/" . $language);
+ include($CONFIG->path . "languages/" . $language);
}
- echo $language;
}
}
diff --git a/languages/en.php b/languages/en.php index e0bc35523..d4c68706c 100644 --- a/languages/en.php +++ b/languages/en.php @@ -6,11 +6,38 @@ * Sessions
*/
- 'login' => "You have been logged in.",
+ 'login' => "Log in",
+ 'loginok' => "You have been logged in.",
'loginerror' => "We couldn't log you in. Make sure your details are correct and please try again.",
- 'logout' => "You have been logged out.",
- 'logouterror' => "We couldn't log you out. We're not sure why, to be honest. Try again?",
+ 'logout' => "Log out",
+ 'logoutok' => "You have been logged out.",
+ 'logouterror' => "We couldn't log you out. Please try again.",
+
+ /**
+ * User details
+ */
+
+ 'username' => "Username",
+ 'password' => "Password",
+
+ /**
+ * Dashboard
+ */
+
+ 'dashboard' => "Dashboard",
+
+ /**
+ * Profile
+ */
+
+ 'profile' => "Profile",
+
+ /**
+ * Account
+ */
+
+ 'account' => "Account",
);
diff --git a/views/default/login.php b/views/default/login.php index b6967ea1b..ab096d41f 100644 --- a/views/default/login.php +++ b/views/default/login.php @@ -15,9 +15,9 @@ <div id="login-box">
<form action="<?php echo $vars['url']; ?>action/login" method="POST">
- <label>Username<br /><input name="username" type="text" class="general-textarea" /></label>
+ <label><?php echo elgg_echo('username'); ?><br /><input name="username" type="text" class="general-textarea" /></label>
<br />
- <label>Password<br /><input name="password" type="password" class="general-textarea" /></label><br />
- <input type="submit" name="submit" value="login" />
+ <label><?php echo elgg_echo('password'); ?><br /><input name="password" type="password" class="general-textarea" /></label><br />
+ <input type="submit" name="submit" value="<?php echo elgg_echo('login'); ?>" />
</form>
</div>
\ No newline at end of file diff --git a/views/default/navigation/topmenu.php b/views/default/navigation/topmenu.php index 106f2873f..571e3e7dc 100644 --- a/views/default/navigation/topmenu.php +++ b/views/default/navigation/topmenu.php @@ -17,9 +17,9 @@ <div id="topmenu">
<ul>
- <li><a href="">dashboard</a></li>
- <li><a href="">profile</a></li>
- <li><a href="">account</a></li>
- <li><a href="">logout</a></li>
+ <li><a href=""><?php echo elgg_echo('dashboard'); ?></a></li>
+ <li><a href=""><?php echo elgg_echo('profile'); ?></a></li>
+ <li><a href=""><?php echo elgg_echo('account'); ?></a></li>
+ <li><a href=""><?php echo elgg_echo('logout'); ?></a></li>
</ul>
</div>
\ No newline at end of file diff --git a/views/default/page_elements/footer.php b/views/default/page_elements/footer.php index 94287f431..5c3ff09d2 100644 --- a/views/default/page_elements/footer.php +++ b/views/default/page_elements/footer.php @@ -16,7 +16,7 @@ <div style="clear:both">
</div><!-- close container div -->
<div id="footer">
-<p>curverider Ltd 2008</p>
+<p><a href="http://elgg.com/">Elgg</a></p>
</div><!-- close footer div -->
</body>
</html>
\ No newline at end of file diff --git a/views/default/welcome.php b/views/default/welcome.php index a9e08148c..f6f7109f9 100644 --- a/views/default/welcome.php +++ b/views/default/welcome.php @@ -16,4 +16,4 @@ ?>
<p>Welcome <?php echo $user; ?></p>
-<p><a href="<?php echo $vars['url']; ?>action/logout">[logout]</a></p>
\ No newline at end of file +<p><a href="<?php echo $vars['url']; ?>action/logout"><?php echo elgg_echo('logout'); ?></a></p>
\ No newline at end of file |