diff -r 1e3b55a591d1 -r be6c5fdd9203 plugins/SpecialUserFuncs.php --- a/plugins/SpecialUserFuncs.php Fri Dec 28 13:36:33 2007 -0500 +++ b/plugins/SpecialUserFuncs.php Mon Dec 31 21:43:51 2007 -0500 @@ -1,8 +1,8 @@ #
Sorry - no users that matched your query could be found. Please try some different search terms.
' : 'Sorry - no users with usernames that start with that letter could be found.
'; + echo ( isset($_GET['finduser']) ) ? '' . $lang->get('userfuncs_ml_err_nousers_find') . '
' : + '' . $lang->get('userfuncs_ml_err_nousers') . '
'; } else { @@ -1745,37 +1755,41 @@ function username($username, $row) { global $db, $session, $paths, $template, $plugins; // Common objects + global $lang; + $userpage = $paths->nslist['User'] . sanitize_page_id($username); - $class = ( isPage($userpage) ) ? ' title="Click to view this user\'s userpage"' : ' class="wikilink-nonexistent" title="This user hasn\'t created a userpage yet, but you can still view profile details by clicking this link."'; + $class = ( isPage($userpage) ) ? ' title="' . $lang->get('userfuncs_ml_tip_userpage') . '"' : ' class="wikilink-nonexistent" title="' . $lang->get('userfuncs_ml_tip_nouserpage') . '"'; $anchor = '' . htmlspecialchars($username) . ''; if ( $session->user_level >= USER_LEVEL_ADMIN ) { $anchor .= ' - Administer user'; + onclick="ajaxAdminUser(\'' . addslashes(htmlspecialchars($username)) . '\'); return false;">' . $lang->get('userfuncs_ml_btn_adminuser') . ''; } return $anchor; } function user_level($level, $row) { global $db, $session, $paths, $template, $plugins; // Common objects + global $lang; switch ( $level ) { case USER_LEVEL_GUEST: - $s_level = 'Guest'; break; + $s_level = $lang->get('userfuncs_ml_level_guest'); break; case USER_LEVEL_MEMBER: case USER_LEVEL_CHPREF: - $s_level = 'Member'; break; + $s_level = $lang->get('userfuncs_ml_level_member'); break; case USER_LEVEL_MOD: - $s_level = 'Moderator'; break; + $s_level = $lang->get('userfuncs_ml_level_mod'); break; case USER_LEVEL_ADMIN: - $s_level = 'Site administrator'; break; + $s_level = $lang->get('userfuncs_ml_level_admin'); break; default: - $s_level = 'Unknown (level ' . $level . ')'; + $s_level = $lang->get('userfuncs_ml_level_unknown', array( 'level' => $level )); } return $s_level; } function email($addy, $row) { + global $lang; if ( $row['email_public'] == '1' ) { global $email; @@ -1784,7 +1798,7 @@ } else { - return '<Non-public>'; + return '<' . $lang->get('userfuncs_ml_email_nonpublic') . '>'; } } /** @@ -1795,6 +1809,7 @@ function format_date($time) { + global $lang; // Our formattting string to pass to date() // This should not include minute/second info, only today's date in whatever format suits your fancy $formatstring = 'F j, Y'; @@ -1814,16 +1829,16 @@ if ( $then == $days_ago ) { // yes, return $i - return "$i days ago"; + return $lang->get('userfuncs_ml_date_daysago', array('days_ago' => $i)); } } // either yesterday, today, or before 6 days ago switch($then) { case $today: - return 'Today'; + return $lang->get('userfuncs_ml_date_today'); case $yesterday: - return 'Yesterday'; + return $lang->get('userfuncs_ml_date_yesterday'); default: return $then; }