diff options
author | alecpl <alec@alec.pl> | 2010-09-29 12:36:28 +0000 |
---|---|---|
committer | alecpl <alec@alec.pl> | 2010-09-29 12:36:28 +0000 |
commit | e99991996dbb9e7b0b0ff6cfa94dc0fb2522eb66 (patch) | |
tree | 8031feaef48d8d30de1253318993f8c0a2223674 /program/include/rcube_template.php | |
parent | d7f9eb573b82ca55c521b68f7cf3ad8de55ab8ba (diff) |
- Add Internationalized Domain Name (IDNA) support (#1483894)
Diffstat (limited to 'program/include/rcube_template.php')
-rwxr-xr-x | program/include/rcube_template.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/program/include/rcube_template.php b/program/include/rcube_template.php index 4dcabb9a1..d923c6478 100755 --- a/program/include/rcube_template.php +++ b/program/include/rcube_template.php @@ -994,15 +994,19 @@ class rcube_template extends rcube_html_page return $username; } + // Current username is an e-mail address + if (strpos($_SESSION['username'], '@')) { + $username = $_SESSION['username']; + } // get e-mail address from default identity - if ($sql_arr = $this->app->user->get_identity()) { + else if ($sql_arr = $this->app->user->get_identity()) { $username = $sql_arr['email']; } else { $username = $this->app->user->get_username(); } - return $username; + return idn_to_utf8($username); } |