PHP Classes

File: example.php

Recommend this page to a friend!
  Classes of George Ariton   PHP Valid MIME Type   example.php   Download  
File: example.php
Role: Example script
Content type: text/plain
Description: Mime class example script
Class: PHP Valid MIME Type
Get the MIME file of file with finfo or file name
Author: By
Last change:
Date: 10 years ago
Size: 214 bytes


Class file image Download
@include_once "Mime.class.php";
$file = "image.jpg";
$mime = Mime::getInstance();
$mimeType = $mime->getMimeType($file);
header('Content-Type: ' . $mimeType);