Forum und email

image_type_to_mime_type

(PHP 4 >= 4.3.0, PHP 5)

image_type_to_mime_type — Ανακτείστε τον Mime-Type για τον τύπο εικόνας, που επιστρέφεται από τις συναρτήσεις getimagesize, exif_read_data, exif_thumbnail, exif_imagetype

Περιγραφή

string image_type_to_mime_type ( int $imagetype )

η συνάρτηση image_type_to_mime_type() θα προσδιορίσει τον Mime-Type για μία IMAGETYPE σταθερά.

Example#1 image_type_to_mime_type (Αρχείο)

<?php
header 
("Content-type: ".image_type_to_mime_type (IMAGETYPE_PNG));
?>

Note: Η συνάρτηση αυτή δεν απαιτεί την GD image library. Ανατρέξτε επίσης στις: getimagesize(), exif_imagetype(), exif_read_data() και exif_thumbnail().