Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
  • #325

    Hey again,

    Thanks so much for your support already, I have one more quick question.

    On the Portfolio Page, I’m wondering if it’s possible, instead of giving users the ability to sort by date or name, to just sort by name automatically and then allow users to sort by category if they choose. The items I’m using in the portfolio are not really date specific and it just seems like unnecessary information for the reader.




    This question was already answered for Cleancut. You can find the post here: (Purchase code hidden if logged out) -sort#post-486

    Because Cleancut and Avisio share big parts of the framework the answer will help you. Please ask if you’ve any problems.

    The Dude


    The code within the template_portfolio.php file of the Cleancut theme does not seem to match the instructions given in that link. It seems the output information is changed somehow, because some of the code suggested in that link does not appear in Cleancut’s file.

    I tried taking the first piece and just deleting the <div> tags around the Sort by Date/Name, but it doesn’t sort the portfolio items in alphabetical order.




    The link posted by Dude is the solution to your question.

    If you’re removing the Date then there’s no need to show the Name as it would be the only option to sort by.

    Best regards,



    Hey guys, sorry again to be a bother. In my template_portfolio.php file, on line 14 I changed this:

    $query_string .= "&post_type=portfolio";

    to this:

    $query_string .= "&post_type=portfolio";
    $query_string .= "&orderby=title";

    The output code that’s shown on the link supplied (the second code that you’re supposed to change) is not found anywhere in the template file for Cleancut, but I’m assuming that because the first piece of code would sort by title automatically, I could just remove this bit:

    <div class='sort_by_val'>
    <span><?php _e('Sort by:','cleancut')?></span>
    <a href="#" id='date_sort' class='active_sort reversed'><?php _e('Date','cleancut')?></a>
    <a href="#" id='name_sort'><?php _e('Name','cleancut')?></a>

    When I do that, the Sort by Date/Name is gone, but the portfolio items are still not sorting in alphabetical order.

    This is my last request I swear!! The site’s almost done, if Kriesi is looking to showcase completed sites using his themes, feel free to use mine!




    Sorry, the linked posts was for Avisio. Made the mistake of not reading things properly.

    The code you posted above is what needs removing to get rid of Date and Name sort.

    Best regards,



    Thanks James! The first piece of code is supposed to sort things by title naturally I assume? That doesn’t appear to be working. The Sort by Date/Name is gone, but now, things just get posted sort of haphazardly, they are certainly not sorted in alphabetical order.


    Interesting, the:


    code should sort posts A – Z…

    Can you set me up a WP username and password and send the details to support {at} jamesmorrisondesign {dot} com with the subject:

    Kriesi | CleanCut | andrewc | Sort By Date Removal

    and I’ll look into it.





    Thanks again, James! Great work!



    You’re welcome Andrew.

    Just for everyones benefit, despite this code working elsewhere:


    I had to modify it to this:


    to get it to work.

    Closing this topic now.



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

The topic ‘"Sort by Date" Removal’ is closed to new replies.