We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the current, buggy behavior
The custom image sizes are listed twice. Once with the correct information and once with the height and width missing.
+-----------------------+-------+--------+------+-------+ | name | width | height | crop | ratio | +-----------------------+-------+--------+------+-------+ | full | | | N/A | N/A | | large | 1024 | 1024 | soft | N/A | | medium_large | 768 | 0 | soft | N/A | | medium | 300 | 300 | soft | N/A | | mini-profile-thumb | 220 | 220 | soft | N/A | | thumbnail | 150 | 150 | hard | 1:1 | | mini-navigation-thumb | 150 | 20 | soft | N/A | | edit-screen-thumb | 120 | 120 | soft | N/A | | mini-frontpage-thumb | 100 | 50 | soft | N/A | | edit-screen-thumb | 0 | 0 | soft | N/A | | mini-profile-thumb | 0 | 0 | soft | N/A | | mini-navigation-thumb | 0 | 0 | soft | N/A | | mini-frontpage-thumb | 0 | 0 | soft | N/A | +-----------------------+-------+--------+------+-------+
Describe how other contributors can replicate this bug
add_image_size( 'mini-profile-thumb', 220, 220 );
wp media image-size
Describe what you would expect as the correct outcome
I expect the result to look as follows
+-----------------------+-------+--------+------+-------+ | name | width | height | crop | ratio | +-----------------------+-------+--------+------+-------+ | full | | | N/A | N/A | | large | 1024 | 1024 | soft | N/A | | medium_large | 768 | 0 | soft | N/A | | medium | 300 | 300 | soft | N/A | | mini-profile-thumb | 220 | 220 | soft | N/A | | thumbnail | 150 | 150 | hard | 1:1 | | mini-navigation-thumb | 150 | 20 | soft | N/A | | edit-screen-thumb | 120 | 120 | soft | N/A | | mini-frontpage-thumb | 100 | 50 | soft | N/A | +-----------------------+-------+--------+------+-------+
Let us know what environment you are running this on
OS: Linux 3.10.0-1062.4.1.el7.x86_64 #1 SMP Wed Sep 25 09:42:57 EDT 2019 x86_64 Shell: PHP binary: /usr/local/bin/php PHP version: 7.1.32 php.ini used: /usr/local/etc/php/php.ini WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli WP-CLI vendor dir: phar://wp-cli.phar/vendor WP_CLI phar path: /app WP-CLI packages dir: WP-CLI global config: WP-CLI project config: /app/wp-cli.yml WP-CLI version: 2.3.0 WordPress version: 5.2.4
Provide a possible solution
The code in the developer handbook is a good solution https://developer.wordpress.org/reference/functions/get_intermediate_image_sizes/#comment-730
The text was updated successfully, but these errors were encountered:
Get custom image sizes only once with the correct info
1b4dc0b
wp-cli#116
6eb76f2
I think this is still happening on 2.6.0.
Sorry, something went wrong.
media image-size
Successfully merging a pull request may close this issue.
Bug Report
Describe the current, buggy behavior
The custom image sizes are listed twice. Once with the correct information and once with the height and width missing.
Describe how other contributors can replicate this bug
add_image_size( 'mini-profile-thumb', 220, 220 );
wp media image-size
Describe what you would expect as the correct outcome
I expect the result to look as follows
Let us know what environment you are running this on
Provide a possible solution
The code in the developer handbook is a good solution https://developer.wordpress.org/reference/functions/get_intermediate_image_sizes/#comment-730
The text was updated successfully, but these errors were encountered: