Skip Navigation

[Resolved] post date showing in sort order when it is not listed as a sort option in backen

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

This topic contains 7 replies, has 2 voices.

Last updated by Nigel 2 years ago.

Assisted by: Nigel.

Author
Posts
#2669289
SCR-20231129-ipvq.png
SCR-20231129-iqcb.png
SCR-20231129-iphn.png

I have a site with a search. The sort options have a post date, even though I do not have it set as an option on the back end.

See attached images. The front end shows 4 sort options.

Post Date,
Posted Date (custom field)
Application Deadline (Custom field)
Post Title

as you can see, post date is not an option I have set up in the sort options backend.

Can you advise. Am I missing a flag somewhere?

Thanks

#2669371

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi there

I just tried this on my local test site, and I'm seeing a similar problem, post_date is included as a sorting option whether you include it or not.

I need to do some further testing to see if I can spot the cause, otherwise I'll need to escalate it to the developers.

I'll get back to you in a little while.

#2669669

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

I spent quite a while, tracking in the code where this goes wrong, but I need some input from the developers, so I have escalated this thread, and I'll get back to you when I have some feedback from them.

#2669673

Thanks.

#2669705

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

OK, the solution is quite simple.

You have added front-end sorting controls, but Views also have an ordering setting (screenshot).

During the implementation of this feature it was decided if the ordering setting wasn't included in the front-end sorting controls, it would be automatically added.

Just change the View ordering setting so that it includes any of the fields used in the front-end ordering controls.

#2669751

Did you intend to include a screenshot?

#2669757

Ok, So there is a beackend view( under Toolset views). If I edit this view and only add the 3 options that I have on the frontend... that they Post date will drop-off? IS this understanding correct?

#2669763

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Screenshot 2023-11-30 at 16.04.12.png

Sorry, I missed this screenshot.

The View has an ordering setting.

If you add Front-end Sorting controls and the same field that is set as the View order is not one of those fields shown on the front-end the field used for the View order setting will automatically be added as well.

#2669875

Found it. Thanks.