php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #70408 Mime::add_mime
Submitted: 2015-09-02 11:51 UTC Modified: 2015-09-02 13:17 UTC
From: admin at angosso dot net Assigned: cmb (profile)
Status: Not a bug Package: *General Issues
PHP Version: 7.0.0RC1 OS: Linux; Windows; Mac
Private report: No CVE-ID: None
 [2015-09-02 11:51 UTC] admin at angosso dot net
Description:
------------
Function adds a MIME type to Apache
LiveAPI PHP Class
mod_php-4.4.0-r9
apache-2.0.54-r31
unable to upgrade to 7. Centos has not marked it stable yet.
mime_content_type() always returns a blank value.
echo mime_content_type('xface.jpg'); 

Test script:
---------------
$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
 
// Add MIME type of text/foo to .foo
$mime_add_mime = $cpanel->uapi(
    'Mime', 'add_mime',
    array(
        'type'       => 'text/index',
        'extension'  => '.exemple',
 )
);
Error: The view for HomeController::display() was not found.
Error: Confirm you have created the file: /home/angosson/rvnewsit/public_html/app/View/Themed/Rvglobal/Home/rundemo.tpl
Notice: If you want to customize this error message, create app/View/Errors/missing_view.ctp

Expected result:
----------------
ext
string	
Required
The file extension to associate with the MIME type.
Any valid file extension.	
.txt
Creates a link to an object


Patches

angosson (last revision 2015-09-02 11:52 UTC by admin at angosso dot net)

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-09-02 13:17 UTC] cmb@php.net
-Status: Open +Status: Not a bug -Package: Java related +Package: *General Issues -Assigned To: +Assigned To: cmb
 [2015-09-02 13:17 UTC] cmb@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 07 12:01:29 2024 UTC