WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to attach files that aren't on the list of supported file types. In this case I'd like to upload files from the media manager that have the .RWP extension (which is used to package files in the Train Simulator 2012 game).

share|improve this question
up vote 2 down vote accepted

You can hook the upload_mimes filter to accomplish this:

add_filter('upload_mimes', 'wpse_43657_upload_mimes');
function wpse_43657_upload_mimes($mime_types){
     $mime_types['rwp'] = 'application/octet-stream';
     return $mime_types;
share|improve this answer
For someone who is still learning to use Wordpress (from a administrators point of view), how would I go about implementing this? – Ambo100 Feb 27 '12 at 14:53
Just place this in your functions.php file in your theme. :) – Brian Fegter Feb 27 '12 at 14:53

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.