This thread is resolved. Here is a description of the problem and solution.
Problem:
If you're experiencing issues with automatically setting the correct listing type for the translated listing post,
Solution:
We recommend trying the following steps:
1. Navigate to
wp-content/themes/my-listing/templates/add-listing/form-fields/admin/select-listing-type.php
in your theme files.
2. Add the following custom code after line number 4:
//convert this slug in current language $post_id = get_page_by_path($value, OBJECT, 'case27_listing_type'); $current_post_id = apply_filters('wpml_object_id', $post_id->ID, 'case27_listing_type'); $value = get_post_field('post_name', $current_post_id);
3. Save the changes and check if the issue persists. We have already added the code on the staging site for you to verify.
Please consult with the theme author to ensure that this modification is acceptable.
Keep in mind that this solution might be outdated or not applicable to your case. If it doesn't resolve your issue, we highly recommend checking the related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If you still need assistance, please open a new support ticket.
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.
This topic contains 7 replies, has 3 voices.
Last updated by 1 year, 5 months ago.
Assisted by: Bruno Kos.