diff options
Diffstat (limited to 'phpBB/includes/mcp/mcp_notes.php')
| -rw-r--r-- | phpBB/includes/mcp/mcp_notes.php | 21 | 
1 files changed, 8 insertions, 13 deletions
| diff --git a/phpBB/includes/mcp/mcp_notes.php b/phpBB/includes/mcp/mcp_notes.php index 02a89c0251..be8e09b0c3 100644 --- a/phpBB/includes/mcp/mcp_notes.php +++ b/phpBB/includes/mcp/mcp_notes.php @@ -2,9 +2,8 @@  /**  *  * @package mcp -* @version $Id$  * @copyright (c) 2005 phpBB Group -* @license http://opensource.org/licenses/gpl-license.php GNU Public License +* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2  *  */ @@ -73,7 +72,7 @@ class mcp_notes  	function mcp_notes_user_view($action)  	{  		global $phpEx, $phpbb_root_path, $config; -		global $template, $db, $user, $auth; +		global $template, $db, $user, $auth, $phpbb_container;  		$user_id = request_var('u', 0);  		$username = request_var('username', '', true); @@ -81,6 +80,7 @@ class mcp_notes  		$st	= request_var('st', 0);  		$sk	= request_var('sk', 'b');  		$sd	= request_var('sd', 'd'); +		$pagination = $phpbb_container->get('pagination');  		add_form_key('mcp_notes'); @@ -174,13 +174,9 @@ class mcp_notes  		}  		// Generate the appropriate user information for the user we are looking at -		if (!function_exists('get_user_avatar')) -		{ -			include($phpbb_root_path . 'includes/functions_display.' . $phpEx); -		}  		$rank_title = $rank_img = ''; -		$avatar_img = get_user_avatar($userrow['user_avatar'], $userrow['user_avatar_type'], $userrow['user_avatar_width'], $userrow['user_avatar_height']); +		$avatar_img = phpbb_get_user_avatar($userrow);  		$limit_days = array(0 => $user->lang['ALL_ENTRIES'], 1 => $user->lang['1_DAY'], 7 => $user->lang['7_DAYS'], 14 => $user->lang['2_WEEKS'], 30 => $user->lang['1_MONTH'], 90 => $user->lang['3_MONTHS'], 180 => $user->lang['6_MONTHS'], 365 => $user->lang['1_YEAR']);  		$sort_by_text = array('a' => $user->lang['SORT_USERNAME'], 'b' => $user->lang['SORT_DATE'], 'c' => $user->lang['SORT_IP'], 'd' => $user->lang['SORT_ACTION']); @@ -216,6 +212,9 @@ class mcp_notes  			}  		} +		$base_url = $this->u_action . "&$u_sort_param$keywords_param"; +		$pagination->generate_template_pagination($base_url, 'pagination', 'start', $log_count, $config['topics_per_page'], $start); +  		$template->assign_vars(array(  			'U_POST_ACTION'			=> $this->u_action,  			'S_CLEAR_ALLOWED'		=> ($auth->acl_get('a_clearlogs')) ? true : false, @@ -226,9 +225,7 @@ class mcp_notes  			'L_TITLE'			=> $user->lang['MCP_NOTES_USER'], -			'PAGE_NUMBER'		=> on_page($log_count, $config['topics_per_page'], $start), -			'PAGINATION'		=> generate_pagination($this->u_action . "&$u_sort_param$keywords_param", $log_count, $config['topics_per_page'], $start), -			'TOTAL_REPORTS'		=> ($log_count == 1) ? $user->lang['LIST_REPORT'] : sprintf($user->lang['LIST_REPORTS'], $log_count), +			'TOTAL_REPORTS'		=> $user->lang('LIST_REPORTS', (int) $log_count),  			'RANK_TITLE'		=> $rank_title,  			'JOINED'			=> $user->format_date($userrow['user_regdate']), @@ -247,5 +244,3 @@ class mcp_notes  	}  } - -?>
\ No newline at end of file | 
