php8.5
Home/ Manual/ exif / functions/ exif_tagname

exif_tagname

PHP function Edit on GitHub ✎

(PHP 4 >= 4.2.0, PHP 5, PHP 7, PHP 8)

Get the header name for an index

Description

exif_tagname(int $index): string|false

Parameters

index

The Tag ID for which a Tag Name will be looked up.

Return Values

Returns the header name, or false if index is not a defined EXIF tag id.

Examples

exif_tagname() example

php
<?php
echo "256: ".exif_tagname(256).PHP_EOL;
echo "257: ".exif_tagname(257).PHP_EOL;
?>

The above example will output:

output
256: ImageWidth
257: ImageLength

See Also

Source: reference/exif/functions/exif-tagname.xml · from the official PHP manual (php/doc-en)