1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

"Sort By" where did you go?

Discussion in 'Styling and Customization Questions' started by Neil E., Nov 21, 2012.

  1. Neil E.

    Neil E. Active Member

    The header bar above the thread list has several sections that allow for sorting by title, start date, replies, views and last message. From the thread_list template:

    Code:
        <dl class="sectionHeaders">
            <dt class="posterAvatar"><a><span>{xen:phrase sort_by}:</span></a></dt>
            <dd class="main">
                <a href="{xen:link forums, $forum, '_params={$orderParams.title}'}" class="title"><span>{xen:phrase title}{xen:helper sortArrow, $order, $orderDirection, title}</span></a>
                <a href="{xen:link forums, $forum, '_params={$orderParams.post_date}'}" class="postDate"><span>{xen:phrase start_date}{xen:helper sortArrow, $order, $orderDirection, post_date}</span></a>
            </dd>
        </dl>
    The sort by doesn't show up in the header bar. I'm sure I've seen it in the past, is there some condition required for it to show up? I also don't see the sort by on this support forum. What am I missing?
     
  2. ManOnDaMoon

    ManOnDaMoon Well-Known Member

    Isn't this in the bottom of the list, visible after clicking "Thread display options"?
     
    Jake Bunce and Russ like this.
  3. Neil E.

    Neil E. Active Member

    Yes that is another way to do some sorting. I'm talking about the "quick method" using the header bar.
    I believe the text "sort by" should show up to the left of "title", as per this picture.

    xenforo82.jpg
     
  4. Russ

    Russ Well-Known Member

    No text that I know of, you can click the header bars to sort them though. They should have a hover effect assuming you haven't adjusted that color.
     
    Jake Bunce likes this.
  5. Neil E.

    Neil E. Active Member

    Ok, then let's look at it the other way round. Where does the sort by in that template show up?
     
  6. ManOnDaMoon

    ManOnDaMoon Well-Known Member

    OK I see your point: the prase sort_by is inserted but somehow invisible.

    I took a look, and the phrase only appears if you change
    HTML:
    <dt class="posterAvatar">
    to
    HTML:
    <dd class="posterAvatar">
    But on my site, it seems to break the style by printing "Sort by" on two separate lines.

    Maybe this should be reported as a minor bug?
     
    Jake Bunce likes this.
  7. Neil E.

    Neil E. Active Member

    That's a good clue. I probably messed around with the template for a different purpose and altered the height or did something else that allowed it to show up. Maybe Jake will explain how to get it on one single line.
     
  8. ManOnDaMoon

    ManOnDaMoon Well-Known Member

    I believe this is an issue with XenForo as is, because it is happening on my working copy. Whether you altered your templates or not, this is not the root cause of the "Sort by" phrase not showing. Probably a missing entry in XF CSS.
     
    Jake Bunce likes this.
  9. Neil E.

    Neil E. Active Member

    Agreed, when I inspect that portion of the header it show a blank link. The class is posterAvatar.

    xenforo83.jpg
     
  10. Neil E.

    Neil E. Active Member

    It's not a CSS issue. It has to do with how the phrase is positioned in the template. I've tried some variations and got a messed up two line header; probably similar to what you found.
     
  11. ManOnDaMoon

    ManOnDaMoon Well-Known Member

    Well, the CSS could be missing a property setting a wider column.

    I am currently writing the bug report.
     
    Jake Bunce likes this.
  12. Neil E.

    Neil E. Active Member

    I can't find a way to fix the template to get it located so I can try some CSS tweaking. Thanks for submitting the report.
     
  13. Russ

    Russ Well-Known Member

    Jake Bunce likes this.
  14. Neil E.

    Neil E. Active Member

    Thanks Russ, that fix worked fine. Perhaps somewhere along the way the "sort by" text was thought to be superfluous.
     

Share This Page