If you are using a custom theme or plugin, you can contact the theme or plugin developer and confirm if the texts are translatable. If they are, you can then visit our page about finding strings that don't appear in String Translation. This page includes step-by-step text and video tutorials about translating different types of strings.
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.
Tell us what you are trying to do?
I'm trying to translate strings in my custom made wordpress theme.
WPML was able to detect strings but when I translate them they were not showing up in the front-end.
Then, following a guide found in your support, I went in the "String translation" menu and deleted the strings that were already translated but not showing.
The problem now is that WPML is unable to find those strings anymore.
I go in "theme localization" and scan for strings in the theme, but they don't show up anymore.
I deleted and uploaded the theme again, nothing.
Welcome to the WPML support forum. I will do my best to help you to resolve the issue.
Please visit WPML>>String Translation after a full site backup and enable the *Look for strings while pages are rendered* option of *Auto register strings for translation* section(on the bottom of the screen).
Then visit the frontend pages and go back to WPML>>String Translation to check whether the strings are registered for translation or not.
This option will be disabled in a couple of hours automatically. But will help us to track the issue in similar cases.
Thank you for the updates. Please share the theme code to list that H1 title, it will help us to track the issue.
Also, please tries the following troubleshooting steps after a full site backup{mandatory} and make sure the issue is existing or not.
1) Go to WPML>>Support page, click on the Troubleshooting link (blue link in the middle of the page)
2) On the Troubleshooting page, please click on the following options of the *Clean up* section. Wait for confirmation of processing after each one.
- Clear the cache in WPML
- Remove ghost entries from the translation tables
- Fix element_type collation
- Set language information
- Fix WPML tables collation
- Assign translation status to duplicated content
- Fix terms count
- Fix post type assignment
- Cleanup and optimize string tables
- Show custom MO Files Pre-generation dialog box>>Generate .Mo files
3) Scan for the theme strings again from the Themes & Plugins localization
Unfortunately, even after following your instructions and cleaning up everything you told me, I'm still unable to scan new strings from my theme.
The strangest thing is that before deleting those strings, WPML was able to detect them. I think there were ~400 strings in my theme.
But now it doesn't detect anything.
At the following link you'll find the entire code of my theme.
Let me know if it helps: hidden link
Thank you for the details and theme files. I went through the code. The strings are not registering for translation because the code is not following the WordPress localization standards and also the strings are dynamic. So it will not be possible for WordPress and WPML to recognize these strings. Please refer to the following code & documentation for more details.
There are multiple calls for the _u() function in your theme. So the best option will be you can use the following WPML hooks to register & translate the strings inside the _u() function.
Please consult about this with your theme developer. Because we have support limitations for the customized themes & plugins - https://wpml.org/purchase/support-policy/. Thank you for your kind understanding.
--
Thanks!
Bigul
Manage Cookie Consent
We use cookies to optimize our website and services. Your consent allows us to process data such as browsing behavior. Not consenting may affect some features.
Functional
Always active
Required for our website to operate and communicate correctly.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
We use these to analyze the statistics of our site. Collected information is completely anonymous.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
These cookies track your browsing to provide ads relevant to you.