@@ 300-306 (lines=7) @@ | ||
297 | $sizes = []; |
|
298 | foreach ( get_intermediate_image_sizes() as $s ) { |
|
299 | $sizes[ $s ] = [ 'width' => '', 'height' => '', 'crop' => false ]; |
|
300 | if ( isset( $theme_image_sizes[ $s ]['width'] ) ) { |
|
301 | // For theme-added sizes |
|
302 | $sizes[ $s ]['width'] = intval( $theme_image_sizes[ $s ]['width'] ); |
|
303 | } else { |
|
304 | // For default sizes set in options |
|
305 | $sizes[ $s ]['width'] = get_option( "{$s}_size_w" ); |
|
306 | } |
|
307 | ||
308 | if ( isset( $theme_image_sizes[ $s ]['height'] ) ) { |
|
309 | // For theme-added sizes |
|
@@ 308-314 (lines=7) @@ | ||
305 | $sizes[ $s ]['width'] = get_option( "{$s}_size_w" ); |
|
306 | } |
|
307 | ||
308 | if ( isset( $theme_image_sizes[ $s ]['height'] ) ) { |
|
309 | // For theme-added sizes |
|
310 | $sizes[ $s ]['height'] = intval( $theme_image_sizes[ $s ]['height'] ); |
|
311 | } else { |
|
312 | // For default sizes set in options |
|
313 | $sizes[ $s ]['height'] = get_option( "{$s}_size_h" ); |
|
314 | } |
|
315 | ||
316 | if ( isset( $theme_image_sizes[ $s ]['crop'] ) ) { |
|
317 | // For theme-added sizes |