ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Show all images from a gallery category?

October 31, 2007 12:33am

Subscribe [3]
  • #1 / Oct 31, 2007 12:33am

    JayTee

    108 posts

    I have a gallery with multiple categories.  I have no idea how many images are in a particular category.  I want to display *all* thumbnails for the category that the user can click on.  I can’t find anything in the gallery documentation that tells me how to show everything - it insists on having “columns and rows” and setting limits - but no way to show all images.

    Any help?

    Thanks,

    Jon

  • #2 / Oct 31, 2007 2:57am

    CodeOfficer

    53 posts

    I am having the exact same issue ... my temporary solution was to output a higher number of rows than i thought i might need (always) ... not elegant.

    someone please help us with this. very annoying. heh

  • #3 / Oct 31, 2007 10:40am

    Robin Sowell

    13255 posts

    I can’t think of a way to do it using standard tags- leaving off the row/col will result in the default of ‘3’ being used.  Thus the only standard option would be to up the col/row to as high as you’re likely to need.

    You could work around it using a query- and it would likely be possible to use some php to come up with the actual number of rows/cols needed to fit all of your images and use that in the standard tag.  It’s also possible it could be done via extension, though in truth, I didn’t look hard at the options there.

    Keep in mind that for most folks, they really will want a limit on the number shown per page- particularly with images, if you have a lot of them, page load will slow down due to factors outside of EE.  I personally would limit it to 10-12 thumbs max.  This is likely why the issue hasn’t come up before- at least to my knowledge.  That said- if two of you are looking to do the same thing, it might be a good idea to put in a feature request for this ability.

  • #4 / Nov 01, 2007 12:09am

    CodeOfficer

    53 posts

    I personally don’t think EE’s API should default with such a limitation, it should be as open as can be. But I also understand EE might have had good reason for doing so. Who am I to judge.

  • #5 / Nov 01, 2007 10:09am

    Robin Sowell

    13255 posts

    😉  If you’re using the software, you’re in the perfect place to make a judgment.  Though in this case, what you’re shooting for, I’d advise against.  That said- it wouldn’t hurt to make a feature request.  The crew does pay attention.  (And like I say- if it’s mission critical, it could be worked around via a query.)

  • #6 / Nov 01, 2007 11:21am

    JayTee

    108 posts

    I think it’s the assumption that we’ll be putting X number of thumbnails in some sort of “grid” (columns/rows) that make it odd to hack around it.  There are many javascript “lightbox” style image galleries where you can throw up a whole bunch of thumbnails without actually retrieving the full sized images.  The total download size for a bunch of thumbnails really isn’t that much - which is why I had hoped for a way to just pull ‘all’.
     
    I’ll make it a feature request.

  • #7 / Jan 08, 2008 2:40pm

    j25

    47 posts

    So, what if we are not using a table structure at all, instead using CSS floats.  Is there any way to display all thumbnails from a category or gallery?

    This seems like very basic functionality.

    Thanks!

  • #8 / Jan 08, 2008 2:42pm

    Lisa Wess

    20502 posts

    You still need to have a limit, and/or columns and rows, so you’re still going to have a limit.

    I’m going to move this up to the how-to forum to see if anyone has ideas for you on this. =)

  • #9 / Jan 08, 2008 2:50pm

    j25

    47 posts

    Thanks Lisa.  But, when I increase the limit to a number higher than the number of thumbnails I have, only one is still showing.

    {exp:gallery:entries gallery="photos" category="4" limit="8" orderby="random"}
    
    <div class="thumbs">
    
    <ul> 
         <li><a href="http://fullplate.htm">{thumb_url}<span>{title}</span></a></li> 
    </ul>
    
    </div>
    
    {/exp:gallery:entries}
  • #10 / Jan 08, 2008 3:00pm

    Lisa Wess

    20502 posts

    You’re using a single-entry style, you need to use the multi-entry style.  =)

  • #11 / Jan 08, 2008 5:00pm

    j25

    47 posts

    That would probably help 😊

    As far as I can tell from the /docs is that the only difference between the mulit-entry style and the single-entry style is the “entries” opening and closing tags.  Is this correct or am I missing something?


    When I added those tags to my markup, the page produced two areas for thumbnails, but no images (I believe I have four thumbnail images in this category.  Markup below:

    {exp:gallery:entries gallery="photos" category="4" limit="8" orderby="random"}
    
    {entries}
    
    <div class="thumbs">
    
    <ul> 
          <li><a href="http://fullplate.htm">{thumb_url}<span>{title}</span></a></li> 
    </ul>
    
    </div>
    
    
    {/entries}
    
    {/exp:gallery:entries}
  • #12 / Jan 08, 2008 5:03pm

    Lisa Wess

    20502 posts

    It’s also the presence of the rows variable pair.  Have a bit more of a look at it; I’d even recommend copying/pasting that and changing from there - test after each change until you have what you want. =)

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases