Back to GD bbPress Attachments Forum

thumbnails from pictures attachments displayed in columns

Published on: January 11, 2012 at 8:54 pm · By: Anonymous

Is it possible to add a new configuration to the plugin, to select a number of columns to display thumbnails, instead they just show line after line?

Maybe also a frame (border) for each thumbnail whith configurable color to match with themes.

Only suggestions that if possible will improve the plugin.

Viewing 20 replies - 1 through 20 (of 20 total)
  • #13408

    You can modify CSS so that lines (in this case LI tags) are displayed in a row. Ad SS modifications to your theme and you are set, and this can include colors or whatever you need else.

    I will not be adding more styling, because this way it is very basic allowing modifications users want on their end. I can’t predict what anyone want to do in terms of styling, so better not to make it too complex.


    Dev4Press - Premium plugins for WordPress.

  • #13410


    You made a point, I can understand that. I’m totally dumb on coding, if I have a working website it’s because you and a lot of people more produce valuable hard working.

    By what you say I assume it’s a matter of CSS only, so adding some lines to my theme’s CSS I will get it.

    Could you hint me with some basic CSS to implement it to my theme? PLS??

    Still, if it doesn’t brake your policy for free plugins you also have the option to add styling so that dumbs like me can use it with the option of disabling all CSS for developers. I’ve seen that in other plugins.

    Anyway, I really need this styling so time to go deep on CSS, those hints from you are appreciated.

    Again, thanks and great job.

  • #13412

    I’m now trying to make the changes to have thumbnails side by side instead of one at each line.
    My first guess is to add a float: left; line on li tags at gd-bbpress-attachments/css/gd-bbpress-attachments.css as you suggest.

    Strangely this file returns as inactive. Is it normal? Every change I make doesn’t produce any effect.

  • #13413

    Plugin is not loading the stying file, it is embedding it into page header, so changing it has no effect. Point of that file is to use the styling from it, change it and add it to your theme to include what plugin needs and make it look the way you want. When you do that, there is an option on the plugin settings panel to disable embedding default CSS.


    Dev4Press - Premium plugins for WordPress.

  • #13429

    I did it.

    Copied the code from the CSS plugin file and pasted it at my theme’s CSS file. Then I’ve disabled the option of use the default CSS at plugins settings.
    Already made the changes that I need. 2 single lines modification.

    .bbp-attachments ol.with-icons li.bbp-atthumb {
    float: left;
    margin: 8px;
    padding: 0;
    height: auto;

    added float and margin lines, it’s working like a charm except at Internet Explorer 8, luckly I have one PC with that version and doesn’t show one single thumbnail.
    Another detail I’ve noticed is that the Icons clip prior to each topic are gone also.
    Javascript on plugin settings is enabled.

    I can’t dismiss IE8, any help?

    Thanks in advance

  • #13430

    I’m close now,

    – The datail of the icons clip not showing it’s solved. The url from the icons.png file had to be updated.
    – I’ve been searching the web and it seems that IE8 with windows XP doesn’t handles good float command. I guess this excerpt can answer what I’m facing:

    floats must always come first before the content you want then to wrap with.

    When you place a float it first creates a new line in IE7 and under and then either floats left or right from there. In good browsers however when you float an item it only creates a new line when there is a block level element before it. If you place a float on the same line as inline content then the inline content on that single lie is shifted either left or right out of the way of the float.

    Therefore to satisfy all browsers you need to make sure that floats always come first.

    So, if this makes sense what can I do to have float coming first?

    Do I have another approach?

  • #13564

    Hi Milan

    I have it working fine on forums doing exactly what I wanted to. The issue with IE8 it’s solved, a float needs a width too, with that IE8 started work.

    As you probably know I have Buddypress too. Buddypress pulls to activity stream all topics and replies from forums. The attachments from plugin are pulled too and displayed.

    Now follows another issue. In forums, attachments are displayed within a li tag from bbp-attachments class, in activity stream they are displayed out of any li tag, so to have those thumbnails having the same styling as they have in forums, that bbp-attachments class defined by the li tag should be present on BP activity stream.

    Is there any easy way to turn this around?

  • #13565

    Plugin has no support for BuddyPress activity stream, and I have no idea how it is displayed there. Plugin only has options to render attached items in the topics and replies. Activity stream does this on its own most likely.


    Dev4Press - Premium plugins for WordPress.

  • #13566

    Activity stream does this on its own most likely.
    Yes it does, there are a lot of coding to to that. basically it grabs everything on a topic on or on a reply and delivers to the stream. Thumbnails from your plugin go together with the relation to colorbox and everything. Concerning your plugin the only thing missing is the style.

    Plugin only has options to render attached items in the topics and replies
    I was hoping to tempting you to add the style class for BP activity stream :)

  • #13567

    I would, but I don’t use BP, and I don’t have it installed on any of my dev websites, and also, I have no idea what needs to be changed to make that work.

    Dev4Press - Premium plugins for WordPress.

  • #13568

    I’m looking for help in Buddypress Forums too.

  • #13572

    If you find what needs to be changed before me, please let me know, and I can add it into plugin.

    Dev4Press - Premium plugins for WordPress.

  • #13646

    I have already the first reaction to my help request on Buddypress forums.
    I’m not sure if this makes sense or not but here it goes:

    The reason why the images cannot be styled in one line is because the GD plugin adds a break “ after each image. If plugin dev removes those generated breaks then you can add the following in your stylesheet.
    `a.cboxElement img {
    float: left;
    padding: 3px;

    Just to check, does the plugin adds those line breaks? I didn’t see them in forums, but I saw in activity stream.

  • #13647

    Nope, no line breaks from the plugin. Each image is in the DIV and each DIV in LI element, no empty spaces or line breaks added there at all.


    Dev4Press - Premium plugins for WordPress.

  • #13774

    I’m still trying to find any help for this, there’s one more message sent to Buddypress team. Whlile messaging I think I found why Buddypress pulls updates from forums to activity stream.

    This file belongs to bbpress plugin: bbpress/bbp-includes/bbp-extend-buddypress.php

  • #13828


    Is that file make sense for you?

    Still no answer at Buddypress forums or team.

    I recall, the issue here is to have activity stream grouping all thumbnails on a li tag as bbpress does. Right now they show at activity stream like this:

    This the place where the topic reply is placed/p>


  • #13829

    I tried to reproduce some html, used the code tag but strangely something didn’t work.

    Is it possible to drop me an email, so we can discuss this a little deeper?

  • #14005

    Hi Milan

    I’m still in circles with this. Unfortunately I’m not a coder so there isn’t much that I can do on my own.

    However I’ve been looking at plugin’s files, bbpress and Buddypress’s files.
    As far as I can see there’s one function in plugin used to build the list elements which is embed_attachments that later is refered at this code:
    add_action(“bbp_get_reply_content”, array(&$this, “embed_attachments”), 10, 2);
    add_action(“bbp_get_topic_content”, array(&$this, “embed_attachments”), 10, 2);

    I suppose this code blends GD attachments content with forum topics or forum replies content.

    As mentioned before bbpress has a file to set forums activities to Buddypress activity stream: bbpress/bbp-includes/bbp-extend-buddypress.php
    This file has the function to set a new activity stream event for each update forums have. That’s where the functions bbp_get_topic_content or bbp_get_reply_content are used to replicate what’s within the updates and to set new variables which Buddypress will need to use.

    I suppose the reading of bbp_get_topic_content or the same for reply doesn’t return a list element tag but probably an array of every div elements inside a topic or a reply, that when rendered in A stream are separated by a break line.

    Is this make sense?

    If you want, please take a look at the file I attached to this message. It’s a copy of the code from the bbpress file that handles the forums updates to Buddypress activity stream.

  • #14009


    I don’t have any update on this, because I don’t have the time to understand all that BuddyPress does. To be honest, I gave up on BuddyPress a while back because in each major version they make changes that break old things. As soon as I get some time to do this, I will, but I can’t promise you when that will be.

    I am 100% sure that my rendered HTML has no breaks, and I can’t fix either bbPress or BuddyPress to do it right. Most likely their code that does some of the rendering or parsing is adding breaks, but again, I don’t have a time to go through someone else code to find out what is going on.


    Dev4Press - Premium plugins for WordPress.

  • #14016

    And I’m sure too that your html doesn’t add those lines breaks, another thing I’m sure is that activity stream doesn’t build a list element tag to render the thumbnails and the thumbnails doesn’t show by the embed_attachments function but by the output at forums topics or replies.

    Anyway I will keep looking to a way to fix this.

Viewing 20 replies - 1 through 20 (of 20 total)
  • The topic ‘thumbnails from pictures attachments displayed in columns’ is closed to new replies.