This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
- | 12:00 – 14:00 | 12:00 – 14:00 | 12:00 – 14:00 | 12:00 – 14:00 | 12:00 – 14:00 | - |
- | 17:00 – 21:00 | 17:00 – 21:00 | 17:00 – 21:00 | 17:00 – 21:00 | 17:00 – 21:00 | - |
Supporter timezone: Europe/Vienna (GMT+02:00)
Related documentation:
This topic contains 17 replies, has 0 voices.
Last updated by edmondC-2 7 hours, 30 minutes ago.
Assisted by: Bigul.
Author | Posts |
---|---|
May 21, 2025 at 8:00 am #17055472 | |
edmondC-2 |
问题的背景: 症状 问题 |
May 21, 2025 at 3:00 pm #17058196 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Maybe you are facing this issue because of compatibility conflicts. To confirm, please follow the steps below on your staging (test) site, if possible, and let us know your feedback. a) Backup your staging (test) first[Mandatory] -- Bigul |
May 22, 2025 at 2:13 am #17059366 | |
edmondC-2 |
I copied a backup website, can you help me debug and identify the problem |
May 22, 2025 at 8:51 am #17060290 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Thank you for the updates. I am enabling the private option for the next reply. Please share the staging site credentials. Also, allow us to make a copy of the site using the Duplicator plugin (https://wordpress.org/plugins/duplicator/), in case of further debugging and escalation. -- Bigul |
May 22, 2025 at 4:56 pm #17063012 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Thank you for the credentials. I was able to access the staging site backend and performed a few rounds of testing in a minimal setup (Elementor, WooCommerce and WPML plugins are only active). I have one question. Please check the attached images. The products are loading in a different order than the latest created order. So, please visit the Shop page on the staging site (hidden link) and confirm whether it is showing the expected results in Chinese under the minimal setup. -- Bigul |
May 23, 2025 at 1:31 am #17063897 | |
edmondC-2 |
Yes, I saw it. It should be products added at the same time because they are ranked first by the latest product. It may be due to the first sorting being (date) and the second sorting being (name). I only have the sorting switch option in the Mentor editor and there are no other sorting rules, or you can see if there are any methods to make their sorting consistent. Thank you |
May 23, 2025 at 9:35 am #17065165 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Thank you for the updates. To make sure, have you selected the *Sort by most recent* option in Appearance >> Customize >> WooCommerce >> Product Catalog >> Default product sorting? Please check the attached image for more details. -- Bigul |
May 23, 2025 at 9:57 am #17065355 | |
edmondC-2 |
Yes, the selection is based on recent additions |
May 26, 2025 at 7:00 am #17071061 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Thank you for the updates. I have shared the details with our team for an expert opinion. We will get back to you as early as possible. Please wait. -- Bigul |
May 29, 2025 at 11:01 am #17087662 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, We are still working on this bug. The ticket has been escalated to our second-tier team for further investigation. We will get back to you as soon as possible. Please wait. -- Bigul |
June 4, 2025 at 7:08 pm #17107961 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, We are still working on this ticket and have observed that the shop page shows products with the same publish date when viewed in each language. However, the order of these products may differ between English and Chinese. WordPress doesn't apply a secondary sorting rule when multiple products share the same publish date. To ensure consistent product order across languages, we must define a secondary sorting condition, like sorting by price, SKU, or another field. Sorting by title may not work well due to language differences. If your preferred sorting option is not available through the UI, we can add a small custom code snippet to apply it. Please let us know your preferred secondary sort method so we can guide you accordingly. -- Bigul |
June 6, 2025 at 1:45 am #17112744 | |
edmondC-2 |
The preferred secondary sorting method uses SKU because this field is consistent in both Chinese and English |
June 6, 2025 at 8:26 am #17113196 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, Thank you for the updates. I will consult with our team and get back to you as soon as possible. Please wait. -- Bigul |
June 11, 2025 at 4:42 pm #17127315 | |
Bigul WPML Supporter since 01/2013
Languages: English (English ) Timezone: Europe/Vienna (GMT+02:00) |
Hello, We are getting the expected results on your staging site after adding the following snippet to the theme’s functions.php file. This code sorts the products first by date and then by SKU. Please check the results and let us know your feedback. Refer to the attached images for more details. add_action('pre_get_posts', 'custom_modify_shop_query', PHP_INT_MAX); function custom_modify_shop_query($query) { // Only modify the shop order if an order has not been specified if ( !isset($_GET['orderby']) && !is_admin() && $query->is_main_query() && is_shop()) { // Set meta_key so SKU ordering works $query->set('meta_key', '_sku'); // Set orderby to array: first by date, then by SKU $query->set('orderby', array( 'date' => 'DESC', 'meta_value' => 'ASC', )); } } -- Bigul |
June 12, 2025 at 2:21 am #17128158 | |
edmondC-2 |
Hello, the sorting of the product homepage is consistent, but when selecting a category to view the products, it is still inconsistent. Could you please solve this problem as well, |