summaryrefslogtreecommitdiffstats
path: root/authfas.module
diff options
context:
space:
mode:
authorPaul W. Frields <stickster@gmail.com>2010-07-18 11:07:04 -0400
committerPaul W. Frields <stickster@gmail.com>2010-07-18 11:07:04 -0400
commit46f9b8adc3af2c74b92124ee6d0adeb8503bd825 (patch)
tree56fa7ea054b261e1f93ef51f1298e82beac8f813 /authfas.module
parent29df4b017c28fe2bd689e53abe3519ae4e2bd546 (diff)
downloaddrupal-authfas-6x-46f9b8adc3af2c74b92124ee6d0adeb8503bd825.tar.gz
drupal-authfas-6x-46f9b8adc3af2c74b92124ee6d0adeb8503bd825.tar.xz
drupal-authfas-6x-46f9b8adc3af2c74b92124ee6d0adeb8503bd825.zip
Improve i18n with string markup and removing acronyms
Diffstat (limited to 'authfas.module')
-rw-r--r--authfas.module14
1 files changed, 7 insertions, 7 deletions
diff --git a/authfas.module b/authfas.module
index 8ba547d..2ca3728 100644
--- a/authfas.module
+++ b/authfas.module
@@ -161,7 +161,7 @@ function authfas_admin_validate($form, &$form_state) {
$response = authfas_fas_login($username, $password, 'https://'.$fasurl.'/json/', 'Accept: application/json;');
if (!isset($response["help"])) {
- form_set_error("authfas_fasurl", t('Could not verify FAS username.'));
+ form_set_error("authfas_fasurl", t('Could not verify FAS username <em>@username</em>.', array('@username' => $username)));
return FALSE;
}
// else we're peachy
@@ -215,9 +215,9 @@ function authfas_user_admin_role_submit($form, &$form_state) {
if (($op == t('Delete role')) or ($fasgroup == '')) {
$result = db_query("DELETE FROM {authfas_ridmap} WHERE rid = %d", $rid);
if ($result) {
- drupal_set_message(t('The role has been removed from the FAS group map.'));
+ drupal_set_message(t('The <em>@role</em> role has been removed from the FAS group map.', array('@role' => $name)));
} else {
- form_set_error("DB error");
+ form_set_error(t('Database error'));
}
} // End delete
// If we're saving a role, update the row.
@@ -225,13 +225,13 @@ function authfas_user_admin_role_submit($form, &$form_state) {
if ($current == '') { // Wasn't mapped before
$result = db_query("INSERT INTO {authfas_ridmap} (rid, fasgroup) VALUES (%d, '%s')", $rid, $fasgroup);
if ($result) {
- drupal_set_message('The role has been mapped to FAS group '.$fasgroup.'.');
- } else { form_set_error("DB error"); }
+ drupal_set_message(t('The role <em>@role</em> is now mapped to FAS group <em>@fasgroup</em>.', array('@role' => $name, '@fasgroup' => $fasgroup)));
+ } else { form_set_error(t('Database error')); }
} else { // Was mapped before
$result = db_query("UPDATE {authfas_ridmap} SET fasgroup = '%s' WHERE rid = %d", $fasgroup, $rid);
if ($result) {
- drupal_set_message('The role has been mapped to FAS group '.$fasgroup.'.');
- } else { form_set_error("DB error"); }
+ drupal_set_message(t('The <em>@role</em> role is now mapped to FAS group <em>@fasgroup</em>.', array('@role' => $name, '@fasgroup' => $fasgroup)));
+ } else { form_set_error(t('Database error')); }
} // End mapped before
} // End insert/update
}