The MU forums have moved to WordPress.org

noflash uploader for mac os x (3 posts)

  1. PerS
    Member
    Posted 17 years ago #

    I've been struggling getting the flash uplader working on my wpmu 2.6.5 site, luckily I found an "explanation" why it's not working at http://www.chewie.co.uk/general/wordpress-image-upload-http-error/ and a solution: the noflash uploader plugin.

    Since my site will have both mac and non-mac users, I modified the plugin so it only turn off flash uploading when you're on a mac. Here's the modified plugin:

    add_filter('flash_uploader', 'noflashuploader');
    function noflashuploader(){
      $user_agent = isset($_SERVER['HTTP_USER_AGENT']) ? strtolower($_SERVER['HTTP_USER_AGENT']) : '';
      if(strpos($user_agent, 'mac') !== false) {
        return false;
      } else {
        return true;
      }
    }
  2. tdjcbe
    Member
    Posted 17 years ago #

    *chuckle* Pesky Mac users. :)

  3. PerS
    Member
    Posted 17 years ago #

    yepp, we are :)

About this Topic