-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Localization not work in the customization widget template #17269
Comments
I guess the PO identifiers don't match for the admin template. @hishamco perhaps you can chime in? |
If those are custom localization resources you need to define them in PO files, try to add |
I will try to follow the reproduced steps and check |
@gaojianzhuang how do you inject or display the search widget in your layout, unfortunately, I didn't use the built-in search form before, but I could figure out the localization issue once the search box shows up |
I believe the issue is a mismatch between the "context" value of the localization string and the one we use for an admin template. For file-system templates we use the filename, and it's set in each PO localization string. For an admin template I assume we could use the name of the template, but I am not even sure we set anything. So it's possible this has never worked. |
We triaged this issue and set the milestone according to the priority we think is appropriate (see the docs on how we triage and prioritize issues). This indicates when the core team may start working on it. However, if you'd like to contribute, we'd warmly welcome you to do that anytime. See our guide on contributions here. |
I expect that too, @gaojianzhuang could you please reply to my last comment |
Describe the bug
I have enabled all the culture, localization-related features, and search forms. When I used the built-in search form widget in the layout, the localization worked well when I switched to a different language. But if I created a customization widget template in the backend. The localization would not work anymore when I changed the language.
Orchard Core version
orchardcore 2.1.0
To Reproduce
Expected behavior
The localization should work well if I use the widget template created in the backend.
zh-CN:
en-US:
It seems like the "{{ "Enter your search term(s)" | t }}" code does not work in the template data.
Logs and screenshots
zh-CN:
en-US
The text was updated successfully, but these errors were encountered: