Skip to:

Image upload

  • joesed



    In my opinion, one of the most useful aspects of any forum is the ability for users to upload and share images.

    Unless I’m missing something, bbpress doesn’t seem to have particularly good functionality in this regard.

    I notice that there are a couple of plugins that support users uploading images, however they seem to be fairly old and unsupported.

    Is the ability to add images to forum posts using current technology (ajax) likely to be something given attention in future releases of bbpress?

    Many thanks


Viewing 11 replies - 1 through 11 (of 11 total)

  • Shmoo


    There is an option but it’s so WordPress. (half done)

    This will add a WP Media upload button above the form.

    <?php bbp_the_content( array( 'context' => 'topic', 'media_buttons' => true, ) ); ?>



    Hi Shmoo

    Thanks for your reply. If you can let me know where this code should go (i.e. which file and approximate line number), that’d be much appreciated.

    I’m really surprised that bbpress doesn’t have much better image upload functionality. If it did it would be right up there with other forum software. As it is, it seems inferior.

    Once again, thanks




    Yeah but they don’t wish to be like other forum software I guess.

    bbPress wants to stay very clean, lean en mean I think. They hope somebody will ever make plugins for bbPress to accomplish all those tasks even history has proven Plugins aren’t the best way to go forward.

    The code-snippet should go in the template that handles the form-stuff.

    Find the next files.
    wp-content / pluings / bbpress / templates / default / bbpress / form-topic.php
    wp-content / plugins / bbpress / templates / default / bbpress / form-reply.php

    Copy & paste ( don’t drag & drop ) both files to your theme folder inside a new fodler called bbpress.
    wp-content / themes / your-theme-name / bbpress / ** paste them here **

    Open the files and search for a line that say:
    <?php bbp_the_content( …. ); ?>

    Line 66 and 92 I think it is.
    Change the code and Save it.

    Refresh the page and you should see a Media upload button above the toolbar.



    Hi Shmoo

    Thanks so much. I really appreciate all of your help with this.

    Much respect.




    Hi @macpresss,

    The ‘media_buttons’ => true, ), seems to be not working.
    Are there any solutions for this?
    I really don’t want to use plugin for this.
    I hope for your response.




    @macpresss, that tip helped me out, however I am getting an upload error when I try to add an image. Though if I refresh the page the image is uploaded. Any ideas?



    ^ the user needs to have the correct rights for example

    function add_theme_caps() {
        $role = get_role( 'contributor' );
        $role->add_cap( 'upload_files' ); 
    add_action( 'admin_init', 'add_theme_caps');

    If you want to add contributors and above to be able to upload_files, change that to subscriber if you want



    Hi guys!

    First, sorry for my bad english 😉

    I try to use bbPress and need add the option to upload some img in the forum.

    Well, with this steps i can see the button “Add object” but, when i push this, don’t works!

    ¿Anybody can help me? Thanks!! @macpresss

    For an alternative way to add inline images to topics and replies without cluttering up the WordPress media system or editing user capabilities, check out our new “Image Upload for BBPress” plugin on the WordPress repository:



    @hearken Your plugin looks good, a much needed function for many bbpress users. Thank you for sharing this with us 🙂

    @PinkishHue Glad to hear it’s useful! We built it after looking for a way to enable inline image uploads on a client’s bbPress forums and not finding anything.

Viewing 11 replies - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.
Skip to toolbar