[DOC-CVS] [doc-en] master: IMAGETYPE_HEIF: Add newly added constant introduced in PHP 8.5 (#5042)

[email protected] (Rodrigo Primo via GitHub) Fri, 8 May 2026 15:28:53 +0000
Newsgroups php.doc.cvs
Message-ID <[email protected]>
Author: Rodrigo Primo (rodrigoprimo)
Committer: GitHub (web-flow)
Pusher: jordikroon
Date: 2026-05-08T17:28:50+02:00

Commit: https://github.com/php/doc-en/commit/f8bab1dfb5246788f144103de56208dd133e9461
Raw diff: https://github.com/php/doc-en/commit/f8bab1dfb5246788f144103de56208dd133e9461.diff

IMAGETYPE_HEIF: Add newly added constant introduced in PHP 8.5 (#5042)

Changed paths:
  M  appendices/migration85/constants.xml
  M  reference/exif/functions/exif-imagetype.xml
  M  reference/image/constants.xml
  M  reference/image/functions/image-type-to-mime-type.xml


Diff:

diff --git a/appendices/migration85/constants.xml b/appendices/migration85/constants.xml
index 0b8a86d31536..57ab491216dc 100644
--- a/appendices/migration85/constants.xml
+++ b/appendices/migration85/constants.xml
@@ -160,6 +160,9 @@
   <title>Standard</title>
 
   <simplelist>
+   <member>
+    <constant>IMAGETYPE_HEIF</constant>
+   </member>
    <member>
     <constant>IMAGETYPE_SVG</constant>
     when libxml is loaded.
diff --git a/reference/exif/functions/exif-imagetype.xml b/reference/exif/functions/exif-imagetype.xml
index d1190c18632a..432194cbae45 100644
--- a/reference/exif/functions/exif-imagetype.xml
+++ b/reference/exif/functions/exif-imagetype.xml
@@ -135,6 +135,10 @@
         <entry>19</entry>
         <entry><constant>IMAGETYPE_AVIF</constant></entry>
        </row>
+       <row>
+        <entry>20</entry>
+        <entry><constant>IMAGETYPE_HEIF</constant></entry>
+       </row>
       </tbody>
      </tgroup>
     </table>
@@ -174,6 +178,12 @@
         Added AVIF support.
        </entry>
       </row>
+      <row>
+       <entry>8.5.0</entry>
+       <entry>
+        Added HEIF support.
+       </entry>
+      </row>
      </tbody>
     </tgroup>
    </informaltable>
diff --git a/reference/image/constants.xml b/reference/image/constants.xml
index 69b5555fbd2f..2c220c056861 100644
--- a/reference/image/constants.xml
+++ b/reference/image/constants.xml
@@ -701,6 +701,18 @@
     </simpara>
    </listitem>
   </varlistentry>
+  <varlistentry xml:id="constant.imagetype-heif">
+   <term>
+    <constant>IMAGETYPE_HEIF</constant>
+    (<type>int</type>)
+   </term>
+   <listitem>
+    &gd.constants.type;
+    <simpara>
+     (Available as of PHP 8.5.0)
+    </simpara>
+   </listitem>
+  </varlistentry>
   <varlistentry xml:id="constant.imagetype-unknown">
    <term>
     <constant>IMAGETYPE_UNKNOWN</constant>
diff --git a/reference/image/functions/image-type-to-mime-type.xml b/reference/image/functions/image-type-to-mime-type.xml
index a21efc679b53..bffb2c50ac7e 100644
--- a/reference/image/functions/image-type-to-mime-type.xml
+++ b/reference/image/functions/image-type-to-mime-type.xml
@@ -125,6 +125,10 @@
        <entry><constant>IMAGETYPE_AVIF</constant></entry>
        <entry><literal>image/avif</literal></entry>
       </row>
+      <row>
+       <entry><constant>IMAGETYPE_HEIF</constant></entry>
+       <entry><literal>image/heif</literal></entry>
+      </row>
      </tbody>
     </tgroup>
    </table>