[ Index ]

PHP Cross Reference of phpBB-3.3.11-deutsch

title

Body

[close]

/phpbb/mimetype/ -> content_guesser.php (source)

   1  <?php
   2  /**
   3  *
   4  * This file is part of the phpBB Forum Software package.
   5  *
   6  * @copyright (c) phpBB Limited <https://www.phpbb.com>
   7  * @license GNU General Public License, version 2 (GPL-2.0)
   8  *
   9  * For full copyright and license information, please see
  10  * the docs/CREDITS.txt file.
  11  *
  12  */
  13  
  14  namespace phpbb\mimetype;
  15  
  16  class content_guesser extends guesser_base
  17  {
  18      /**
  19      * {@inheritdoc}
  20      */
  21  	public function is_supported()
  22      {
  23          return function_exists('mime_content_type') && is_callable('mime_content_type');
  24      }
  25  
  26      /**
  27      * {@inheritdoc}
  28      */
  29  	public function guess($file, $file_name = '')
  30      {
  31          return mime_content_type($file);
  32      }
  33  }


Generated: Sat Nov 4 14:26:03 2023 Cross-referenced by PHPXref 0.7.1