Skip Navigation

[Resolved] Sort by content of select field

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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 5 replies, has 2 voices.

Last updated by alexanderP-4 1 year, 9 months ago.

Assisted by: Minesh.

Author
Posts
#2569115

Tell us what you are trying to do?
I have a custom post type for a list of experts. They have different memberships and I want to sort them by membership. To do this I added a new field "membership" to the custom post type. In the custom post type form you can select the three memberships with a drop down select field. Now I try to sort the view by this field, but the view ignors it and only sort by the second sort criteria "name"

The three memberships are:
A-Premium
B-Top
C-Berater

Is there any documentation that you are following?
I tried to find a solution on your site.
Is there a similar example that we can see?
hidden link
What is the link to your site?
hidden link

#2569151

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

I will have to check what its not soring the results.

Can you please tell me you want to order the result by ASC or DESC and share admin access details.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#2569205

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

I see you are using the Elementor and using the views widget.
=> hidden link

I would suggest instead of using the view widget you should add a Text widget and add the view's shortcode to it and save your elementor tempalte:

[wpv-view name="berater_innen-uebersicht"]
#2569213

Thanks, I have now done so. But still only sort by title not by the primary sorting.

#2569235

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

I see there is no custom code added to custom code section and I'm not sure why its not applying the correct order.

Do you happen to know if you added any related custom code to your theme's functions.php file?

If no:
Could you please try to resolve your issue by deactivating all third-party plugins as well as the default theme to check for any possible conflicts with any of the plugins or themes?
- But as you know this is a live site you will have to create a staging site and check for any plugin/theme conflict.

If that is not an option then I will require duplicator copy of your site. Please let me know if you have any related filer is added that is overriding this.

#2569237

My issue is resolved now. Thank you!