WordPress.org

Support

Support » Plugins and Hacks » bbPress Enable TinyMCE Visual Tab » [Resolved] Allow subscribers to upload media?

[Resolved] Allow subscribers to upload media?

  • Do you think it’s a bad idea to grant subscribers the right to upload media?
    Mostly they would need it for images (in my case). Oh and I disabled the WP admin for them 🙂

    Here’s the code for the functions.php

    add_action('admin_init', 'allow_subscriber_uploads');
    function allow_subscriber_uploads() {
        $subscriber = get_role('subscriber');
        $subscriber->add_cap('upload_files');
    }
    
    add_action('admin_init', 'no_mo_dashboard');
    function no_mo_dashboard() {
      if (!current_user_can('manage_options') && $_SERVER['DOING_AJAX'] != '/wp-admin/admin-ajax.php') {
      wp_redirect(home_url()); exit;
      }
    }

    https://wordpress.org/plugins/bbpress-enable-tinymce-visual-tab/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Jared

    @jaredatch

    There are two big issues, with doing that and why we haven’t added media uploading to bbPress core (yet).

    First is restricting what kind of media they can upload, how big, etc. For example most likely you only want your subscribers to upload jpg/jpeg/gif (image) files and you likely want those to be < 500kb.

    Second, the other issue, if I recall, I ran into when I looked into this was there needs to be a way to filter the media in shown in the Media Gallery.

    For example you don’t want the subscriber to see files uploaded by other subscribers, or worse, by the administrators. It should either show them no uploaded files or only there own.

    So until those 2 issues are solved, I won’t be recommending or enabling uploads for subscribers. With that said, it’s definitely something I would like to do, I just haven’t had time to research the solutions we need.

    Thanks!

    MarcoDiModena

    @marcodimodena

    Hi guys, did you find any solution? It will be awesome

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Allow subscribers to upload media?’ is closed to new replies.
Skip to toolbar