diff options
| -rw-r--r-- | phpBB/profile.php | 11 | ||||
| -rw-r--r-- | phpBB/viewtopic.php | 11 |
2 files changed, 8 insertions, 14 deletions
diff --git a/phpBB/profile.php b/phpBB/profile.php index 8d45648d9a..1c819e9632 100644 --- a/phpBB/profile.php +++ b/phpBB/profile.php @@ -268,25 +268,22 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) ) $email_img = ""; } + $avatar_img = ""; if( $profiledata['user_avatar_type'] && $profiledata['user_allowavatar'] ) { switch( $profiledata['user_avatar_type'] ) { case USER_AVATAR_UPLOAD: - $avatar_img = '<img src="' . $board_config['avatar_path'] . '/' . $profiledata['user_avatar'] . '" alt="" />'; + $avatar_img = ( $board_config['allow_avatar_upload'] ) ? '<img src="' . $board_config['avatar_path'] . "/" . $profiledata['user_avatar'] . '" alt="" border="0" />' : ''; break; case USER_AVATAR_REMOTE: - $avatar_img = '<img src="' . $profiledata['user_avatar'] . '" alt="" />'; + $avatar_img = ( $board_config['allow_avatar_remote'] ) ? '<img src="' . $profiledata['user_avatar'] . '" alt="" border="0" />' : ''; break; case USER_AVATAR_GALLERY: - $avatar_img = '<img src="' . $board_config['avatar_gallery_path'] . '/' . $profiledata['user_avatar'] . '" alt="" />'; + $avatar_img = ( $board_config['allow_avatar_local'] ) ? '<img src="' . $board_config['avatar_gallery_path'] . '/' . $profiledata['user_avatar'] . '" alt="" border="0" />' : ''; break; } } - else - { - $avatar_img = ""; - } $poster_rank = ""; $rank_image = ""; diff --git a/phpBB/viewtopic.php b/phpBB/viewtopic.php index 49b422d077..61161c0da5 100644 --- a/phpBB/viewtopic.php +++ b/phpBB/viewtopic.php @@ -816,25 +816,22 @@ for($i = 0; $i < $total_posts; $i++) $poster_joined = ( $postrow[$i]['user_id'] != ANONYMOUS ) ? $lang['Joined'] . ": " . create_date($lang['DATE_FORMAT'], $postrow[$i]['user_regdate'], $board_config['board_timezone']) : ""; + $poster_avatar = ""; if( $postrow[$i]['user_avatar_type'] && $poster_id != ANONYMOUS && $postrow[$i]['user_allowavatar'] ) { switch( $postrow[$i]['user_avatar_type'] ) { case USER_AVATAR_UPLOAD: - $poster_avatar = '<img src="' . $board_config['avatar_path'] . "/" . $postrow[$i]['user_avatar'] . '" alt="" border="0" />'; + $poster_avatar = ( $board_config['allow_avatar_upload'] ) ? '<img src="' . $board_config['avatar_path'] . "/" . $postrow[$i]['user_avatar'] . '" alt="" border="0" />' : ''; break; case USER_AVATAR_REMOTE: - $poster_avatar = '<img src="' . $postrow[$i]['user_avatar'] . "\" alt=\"\" border=\"0\" />"; + $poster_avatar = ( $board_config['allow_avatar_remote'] ) ? '<img src="' . $postrow[$i]['user_avatar'] . '" alt="" border="0" />' : ''; break; case USER_AVATAR_GALLERY: - $poster_avatar = '<img src="' . $board_config['avatar_gallery_path'] . "/" . $postrow[$i]['user_avatar'] . '" alt="" border="0" />'; + $poster_avatar = ( $board_config['allow_avatar_local'] ) ? '<img src="' . $board_config['avatar_gallery_path'] . "/" . $postrow[$i]['user_avatar'] . '" alt="" border="0" />' : ''; break; } } - else - { - $poster_avatar = ""; - } // // Define the little post icon |
