231 | | // Set image width |
232 | | if ( false !== $width ) |
233 | | $html_width = ' width="' . $width . '"'; |
234 | | else |
235 | | $html_width = ( 'thumb' == $type ) ? ' width="' . bp_core_avatar_thumb_width() . '"' : ' width="' . bp_core_avatar_full_width() . '"'; |
| 233 | // set the image width variable |
| 234 | if ( false !== $width ) { |
| 235 | $width = $width; |
| 236 | } elseif ( 'thumb' == $type ) { |
| 237 | $width = bp_core_avatar_thumb_width(); |
| 238 | } else { |
| 239 | $width = bp_core_avatar_full_width(); |
| 240 | } |
| 241 | |
| 242 | // Set html width attribute |
| 243 | $html_width = ' width="' . esc_attr( $width ) . '"'; |
| 244 | |
| 245 | // Set the image height variable |
| 246 | if ( false !== $height ) { |
| 247 | $height = $height; |
| 248 | } elseif ( 'thumb' == $type ) { |
| 249 | $height = bp_core_avatar_thumb_height(); |
| 250 | } else { |
| 251 | $height = bp_core_avatar_full_height(); |
| 252 | } |
| 253 | |
| 254 | $html_height = ' height="' . esc_attr( $height ) . '"'; |
317 | | return apply_filters( 'bp_core_fetch_avatar', '<img src="' . $avatar_url . '" alt="' . esc_attr( $alt ) . '" class="' . esc_attr( $class ) . '"' . $css_id . $html_width . $html_height . $title . ' />', $params, $item_id, $avatar_dir, $css_id, $html_width, $html_height, $avatar_folder_url, $avatar_folder_dir ); |
| 331 | return apply_filters( 'bp_core_fetch_avatar', '<img src="' . $avatar_url . '" class="' . esc_attr( $class ) . '"' . $css_id . $html_width . $html_height . $html_alt . $title . ' />', $params, $item_id, $avatar_dir, $css_id, $html_width, $html_height, $avatar_folder_url, $avatar_folder_dir ); |
379 | | return apply_filters( 'bp_core_fetch_avatar', '<img src="' . $gravatar . '" alt="' . esc_attr( $alt ) . '" class="' . esc_attr( $class ) . '"' . $css_id . $html_width . $html_height . $title . ' />', $params, $item_id, $avatar_dir, $css_id, $html_width, $html_height, $avatar_folder_url, $avatar_folder_dir ); |
| 393 | return apply_filters( 'bp_core_fetch_avatar', '<img src="' . $gravatar . '" class="' . esc_attr( $class ) . '"' . $css_id . $html_width . $html_height . $html_alt . $title . ' />', $params, $item_id, $avatar_dir, $css_id, $html_width, $html_height, $avatar_folder_url, $avatar_folder_dir ); |