This thread is resolved. Here is a description of the problem and solution.
Problem:
The client needed to update a custom string in the AMP theme footer but encountered issues with the string translations not working after the update.
Solution:
We recommended the following steps:
1. Remove the custom HTML code from AMP > Settings > Advanced Settings > Enter HTML in Footer, as this code is not used for translation strings.
<footer> <!-- Your existing footer content here --> <!-- Container for the fixed button --> <div class="amp-button-container"> <a href="https://firstderm.com/ask-online-dermatologist/" class="amp-button">CLICK TO ASK A DERMATOLOGIST</a> </div> </footer>
2. Ensure that the code to register the string for translation is enabled in the
functions.php
file within the child theme folder.
function register_strings_for_translation() { if (function_exists('icl_register_string')) { icl_register_string('first-derm-footer', 'amp-button-text', 'CLICK TO ASK A DERMATOLOGIST'); } } add_action('init', 'register_strings_for_translation');
3. Re-translate the string in WPML > String Translation.
After following these steps, the translation string in the footer should display correctly.
Please note that this solution might be irrelevant if it's outdated or not applicable to your case. If the issue persists, we highly recommend checking 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 1 reply, has 2 voices.
Last updated by 1 year, 2 months ago.
Assisted by: Long Nguyen.