WPDev.one
Core Function
View Source on Trac ↗

wp_image_file_matches_image_meta()

wp_image_file_matches_image_meta( mixed $image_location, mixed $image_meta, mixed $attachment_id = 0 )

Determines if the image meta data is for the image source file.

Parameters 2 required

Name / Type Description
$image_location
string

The full path or URI to the image file.

Required
$image_meta
array

The attachment meta data as returned by 'wp_get_attachment_metadata()'.

Required
$attachment_id
int

Optional. The image attachment ID. Default 0.

Return Value

(bool)
Whether the image meta is for this image file.

Function Information

Since Version
5.5.0
Source File
wp-includes/media.php
Advertisement