+1-888-365-2779
Try Now
More in this section

Forums / General Discussions / Image Gallery Sort Expression

Image Gallery Sort Expression

6 posts, 0 answered
  1. WebGeek
    WebGeek avatar
    186 posts
    Registered:
    20 Dec 2006
    12 Mar 2008
    Link to this post
    I would like to be able to sort my images by their title.  What do I need to put in for the Sort Expression in the advance area?
  2. Tihomir
    Tihomir avatar
    53 posts
    Registered:
    24 Sep 2012
    13 Mar 2008
    Link to this post
    Hello medicalwebgeek,

    By default this control uses "Publication_Date DESC" sorting expression but you can achieve your goal by setting its SortExpression property to "Name ASC".

    You can actually see what meta fields the Libraries module use by checking them in the web.config file - libraryInfo section, metaKeys attribute:

                <libraryInfo> 
                    <add name="Image" title="Image Library" defaultExtenstions=".png, .jpg, .gif" metaKeys="Author, AlternateText, Extension, Name, Height, Width, Size, Category"></add> 
                    <add name="Document" title="Document Library" defaultExtenstions=".doc, .docx, .rtf, .txt, .pdf, .ppt, .pptx, .html, .xls, .xlsx" metaKeys="Author, Description, Extension, Name, Size, Category"></add> 
                    <add name="Custom" title="Custom Library" defaultExtenstions=".*" metaKeys="Author, Description, Extension, Name, Size, Category"></add> 
                </libraryInfo> 

    Hope this helps!

    Sincerely yours,
    Tihomir
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. WebGeek
    WebGeek avatar
    186 posts
    Registered:
    20 Dec 2006
    13 Mar 2008
    Link to this post
    Thanks.  That fixed it.

    I have another question regarding the gallery.  Sometimes when I pull up my gallery page (public) some of the images do not load.  This also happens every so often in the Module area.
  4. Tihomir
    Tihomir avatar
    53 posts
    Registered:
    24 Sep 2012
    13 Mar 2008
    Link to this post
    Hi medicalwebgeek,

    I can acknowledge this issue. We have already had several reports about it and we are trying to find a steady pattern why it is happening. Generally, the problem tends to be in slight differences between the URL of the image and the value which is saved for it in the DB - table sf_CmsContentBase, column Url. It will be really helpful if you find some pattern to notify us.
    Thanks for your cooperation in advance.

    Regards,
    Tihomir
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  5. Eric
    Eric avatar
    19 posts
    Registered:
    06 Nov 2007
    07 Oct 2009
    Link to this post
    Using Sitefinity 3.7, and where I do what you posted I get this error:

    Parser Error Message: Unrecognized attribute 'SortExpression'. Note that attribute names are case-sensitive.
  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    07 Oct 2009
    Link to this post
    Hello Eric,

    You can sort the items by name using the following expression - Name ASC or Name DESC. You can set the sort expression from Image Gallery Control Designer >> Advanced Tab >> Filters >> Sort Expression property. The sorting by name works without problems under Sitefinity 3.7 SP1.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Register for webinar
6 posts, 0 answered