wp_get_webp_info
wp_get_webp_info ( $filename )
Parameters:- (string) filename Path to a WebP file.
Returns:- (array) { An array of WebP image information. @type int|false $width Image width on success, false on failure. @type int|false $height Image height on success, false on failure. @type string|false $type The WebP type: one of 'lossy', 'lossless' or 'animated-alpha'. False on failure. }
Defined at: - Introduced in WordPress: 5.8.0
- Deprecated in WordPress: —
Description
Extracts meta information about a WebP file: width, height, and type.