Numbers in title –> wrong sorting

This topic contains 5 replies, has 2 voices, and was last updated by  Fabian Suter 6 years ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket

Tagged: 

  • Author
    Posts
  • #429523

    Fabian Suter
    Lifetime Member
    Post count: 135

    hello there

    When I have some numbers in a title the sorting function is not working correctly. for example numbers like 1,2,3,4,5,6,7,8,9,10 will be sorted like 1,10,2,3,4,5,6,7,8,9. when I have 1500 entries with such numbers, you can imagine what happens.
    I will show you a picture in a private message to show my problem exactly.

    Best

    #429525

    Fabian Suter
    Lifetime Member
    Post count: 135
    This reply has been marked as private.
    #429529

    Guust
    Moderator
    Post count: 29970

    The sort is not a numerical sort but a text sort, so if you want to sort it, you need to use 0001,0002,0003,0004,0005,0006,0007,0008,0009,0010 etc. Then it will work …

    #429666

    Fabian Suter
    Lifetime Member
    Post count: 135

    Hi Guust

    Thanks. Is it possible to define a field which would be sorted? for example I have a hidden field with the numbers and this is a numeric field. so the sort would work if I can define it in the shortcode? at the moment it takes the title of an object to sort.

    #429687

    Guust
    Moderator
    Post count: 29970

    Add a sort for that hidden custom field then.
    That will only work on the Listing pages, not in shortcodes.

    Thanks

    #429713

    Fabian Suter
    Lifetime Member
    Post count: 135

    I made that. I will test it out 🙂

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

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket