Home›Support›English Support›[Resolved] Technical Validation: Conflict between MotoPress Hotel Booking 5.4.1 and WPML ID Mapping
[Resolved] Technical Validation: Conflict between MotoPress Hotel Booking 5.4.1 and WPML ID Mapping
This thread is resolved. Here is a description of the problem and solution.
Problem: After updating MotoPress Hotel Booking to version 5.4.1, the client encountered issues with rate synchronization and availability displays in a multilingual setup using WPML. The update led to ID mapping shifts, rate/availability desynchronization, and database inconsistencies.
Solution: We recommend the following steps: 1. Ensure that certain post types such as mphb_booking, mphb_season, mphb_room, mphb_payment, mphb_reserved_room, and mphb_coupon are not translated. Set the custom fields like min_price and _mphb_total_price to "Copy" in WPML > Settings > Custom Field Translation to ensure values are copied to translations. 2. If necesary, use the
wpml_object_id
hook for ID adjustments. Documentation can be found here: https://wpml.org/wpml-hook/wpml_object_id/ 3. Set the taxonomy mphb_room_type to "Translatable - only display translated items" in WPML > Settings > Taxonomies Translation and translate the room types at WPML > Taxonomy Translation. 4. Consult with the MotoPress team regarding the integration and potential issues with the plugin.
If these steps do not resolve the issue or if the solution becomes outdated, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If further assistance is needed, please open a new support ticket at WPML support forum.
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.
Following the update of MotoPress Hotel Booking to version 5.4.1, we encountered a critical failure in rate synchronization and availability displays within the multilingual (WPML) environment.
I have performed a deep-dive database analysis and architectural review. Before I finalize the implementation on my production server, I would like your technical team to confirm if the following observations and corrective steps align with WPML’s standard for handling object ID mapping in 2026.
Technical Observations:
ID Mapping Shift: In v5.4.1, MotoPress altered the logic for how Room Type IDs and Rate IDs are queried. In a multilingual setup, the plugin appears to be "losing" the connection between the translated Page/Post ID and the underlying Booking Meta IDs.
Rate/Availability Desync: The update caused the front-end to return null values for rates in secondary languages, even though the database records remained intact. This suggests a failure in the wpml_object_id filter or a direct SQL query by the plugin that bypasses WPML’s translation hooks.
Database Inconsistency: We detected that certain _mphb_ meta keys were not being filtered correctly through the WPML Translation Management layer during the update's migration script.
Steps Taken for Rectification:
Snapshot & Clone: Created a development environment from a production snapshot to isolate the issue.
Meta-Data Audit: Manually verified wp_postmeta for inconsistencies between the min_price and _mphb_total_price across translated string sets.
cureent staging server status the Id are linked in elementor shortcut using corresponding ID languages as before it was the original id been used, now on new version motopress all calendars use the corresponfing id languages
calendars and booking where been tested successfully no double booking on any languages and motopress booking systems are showing the correct room been boolked on any languages
calendars are in sync
we tested everything
Hook Intervention: We are implementing a fix that forces the re-mapping of the target_id using the icl_object_id (or the current wpml_object_id equivalent) to ensure MotoPress pulls the rate from the correct translated ID rather than the original language ID.
Request for Confirmation:
Does WPML have documented compatibility issues with MotoPress 5.4.1 regarding Rate ID mapping?
Does your team recommend a specific filter to ensure that MotoPress’s internal MPH_Room_Type objects are correctly recognized by WPML’s adjust_id logic when the plugin uses custom AJAX endpoints?
I have the logs and the specific SQL diffs available if your developers need to see where the logic breaks.
if the steps i done are the correct way to fix the issues then please let me know so we could close the ticket
Languages: English (English )Spanish (Español )German (Deutsch )
Timezone: America/Lima (GMT-05:00)
Hello,
WPML does not manage any integration for the HotelBooking plugin. It is MotoPress who handles this integration, and I suggest you report opccuring issues to their support team.
You need to make sure to follow this guide and consider known limitations: hidden link
For example, those post types should not be translated:
mphb_booking
mphb_season
mphb_room
mphb_payment
mphb_reserved_room
mphb_coupon
I further suggest you set the custom fields min_price and _mphb_total_price or other related fields that control the settings of each post to "Copy" inside WPML > Settings > Custom Field Translation. If the field is set to "Copy", WPML will make sure that its value is copied over to the translation once you create a translation with the WPML Translation Editor.
Also, make sure that at WPML > Settings > Taxonomies Translation the taxonomy mphb_room_type (Accommodation Types) is set to "Translatable - only display translated items". Do not use the fallback setting. Then translate the room types at WPML > Taxonomy Translation.
Now, I can not confirm if this will actually have any effect, as Motopress says that the related post types mphb_room should not be translated.
I suggest you consult the Motopress Team about it.
If further help from our end is needed, I can offer a WPML test site on which you can install the latest version of the plugin and try to replicate the issue. I can then try veorfy the settings for you and maybe suggest a hook implementation, but the final changes will need to be taken by Motopress.
Thank you for your detailed reply and for the technical insights.
I have reviewed and implemented the options as described. Most of them were very helpful, and while one specific setting didn't quite fit my environment, the overall problem is now resolved.
Since MotoPress support didn't provide any substantial information regarding this specific conflict, your guidance was essential. It confirmed that the adjustments I made to the configuration were correct and allowed me to manage the situation successfully.
I have already ensured that the specific post types (like mphb_booking and mphb_room) remain untranslated and have set the custom fields to "Copy" as suggested to maintain consistency across the engine.
Thank you again for the support and the clear documentation.