WordPress mime-config

What it does

This plugin allows you to configure extra mime-types for support by the inline-uploader.

How it works

A new options page is added as Options … Mime-types which allows you to add/delete the extra mime-types.

screenshot of the plugins options page

By default the following extra mime-types are registered: audio/ac3, audio/MPA and video/x-flv.

With version 0.90 of the plugin you are now able to upload a file containing a long list of mime types as an easy way to register multiple mime-types. The file format is “mime/type extension” for example like this:

    audio/ac3 ac3
    audio/MPA mpa
    video/x-flv flv

Requirements

This plugin requires WordPress 2.0 or later to function as it relies on the existence of the inline-uploader.
With WordPress 2.0.4 or later the plugin will also use the builtin nonce protection for all actions.

Download

The latest version of the plugin may be downloaded here: pjw-mime-config.0.90.zip

39 thoughts on “WordPress mime-config

  1. malin

    Hi Westi,

    I have a big problem.

    I dint read description carefully and I wanted add mime-types from file choosing *.xls (excel) file. I thought that your plugin adds extension and mime type form the file type not from the list in the file.

    Now I have on File extension list many rows with entries like:
    Excel�@��������j� @������s�j� @����EV:�j� ���
    The problem is that I can not delete the rows. There is no error – I choose “delete” then I confirm and the line remains on the list.

    Can I remove the rubbish lines manually or how to restore default settings.
    regards,

    malin

  2. malin: Oh dear! At present the plugin doesn’t have a handy way to clear out the list.

    However, if you copy the following code into a file and add it to your plugins directory you can use it to clear out the extra mime-types easily.

    If you activate this plugin and then deactivate it the extra mimetypes will be cleared out and then you can use the normal plugin ui to add back in the ones you want.

    <?php
    /*
       Plugin Name: PJW Mime Clearer
       Plugin URI: http://blog.ftwr.co.uk/
       Description: Cleans out the extra mime-types.
       Author: Peter Westwood
       Version: 0.000001
       Author URI: http://blog.ftwr.co.uk/
     */
    
    /* Do the work */
    add_action('plugins_loaded', create_function('','update_option(\'pjw_mime_types\',\'\');'));
    ?>

    Hope this helps!

  3. malin

    Hi Peter,

    thank you for the reply.

    unfortunately the PJW Mime Clearer didn’t help ;-(

    After activating all WP pages were blank.

    I had to remove file from plugin directory to make WP work again.
    The mime types are still on the list. (see attachment)

    Where these entries are stored, file or table in db ?
    How to remove them manually?

    Regards,
    malin

  4. They are stored in the db.

    I think you may have had problems with the example plugin due to the way
    in which WordPress converts normal quotes into smart quotes so I have
    sent it to you in an email.

    If this still doesn’t work the entry will be in the options table of the
    WordPress database.

Comments are closed.