| @@ 1133-1141 (lines=9) @@ | ||
| 1130 | } | |
| 1131 | } | |
| 1132 | ||
| 1133 | 			if ( !empty( $img_url ) ) { | |
| 1134 | $image_params['width'] = $thumbnail_size['width']; | |
| 1135 | $image_params['height'] = $thumbnail_size['height']; | |
| 1136 | $image_params['src'] = Jetpack_PostImages::fit_image_url( | |
| 1137 | $img_url, | |
| 1138 | $thumbnail_size['width'], | |
| 1139 | $thumbnail_size['height'] | |
| 1140 | ); | |
| 1141 | } | |
| 1142 | } | |
| 1143 | ||
| 1144 | return $image_params; | |
| @@ 567-570 (lines=4) @@ | ||
| 564 | if ( !$media && $args['from_attachment'] ) | |
| 565 | $media = self::from_attachment( $post_id, $args['width'], $args['height'] ); | |
| 566 | 		if ( !$media && $args['from_html'] ) { | |
| 567 | if ( empty( $args['html_content'] ) ) | |
| 568 | $media = self::from_html( $post_id, $args['width'], $args['height'] ); // Use the post_id, which will load the content | |
| 569 | else | |
| 570 | $media = self::from_html( $args['html_content'], $args['width'], $args['height'] ); // If html_content is provided, use that | |
| 571 | } | |
| 572 | ||
| 573 | 		if ( !$media && $args['fallback_to_avatars'] ) { | |