Dear all,
I've tried to translate Placeholder Text via "User Interface Translation", but it didn't work. Is there any workaround?
Best,
Orkut
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | After Patch 3116477.png | 325.87 KB | chetanbharambe |
| #7 | Before Patch 3116477 Two.png | 372.3 KB | chetanbharambe |
| #7 | Before Patch 3116477 One.png | 342.55 KB | chetanbharambe |
| #4 | 3116477-4.patch | 902 bytes | yogeshmpawar |
Comments
Comment #2
orkutmuratyilmazHello again,
On
/src/Form/BetterSearchSettingsForm.phpfile, line 40 exists as below:'#default_value' => $this->config('better_search.settings')->get('placeholder_text'),If we change it to
'#default_value' => $this->config('better_search.settings')->t('get('placeholder_text')'),, we get WSOD error.How can we change the code?
Have a nice one.
Comment #3
yogeshmpawarChecking the issue.
Comment #4
yogeshmpawarAdding patch will get the translated placeholder text for multilingual sites.
Comment #6
yogeshmpawarCommitted & Pushed to 8.x-1.x branch.
Comment #7
chetanbharambe commentedThanks, @yogeshmpawar for fixing this issue.
Tested and working as expected.
Testing Steps:
# Goto: Appearance -> Apply Seven theme
# Goto: Extend: Install Configuration, Content and Interface translation also Add new Module: "Better search block" and Install it
# Goto: admin/config/regional/language
# Add any new language like French, Polish
# Goto: admin/config/search/better-search
# Add the word which user has to translate in placeholder text
# Goto: admin/config/regional/translate
# Search the keyword and translate it in the respective language and save the translation.
# Again Go to: admin/config/search/better-search
# User should see saved translation in the placeholder.
Expected Results:
# User should see saved translation in placeholder text Text via "User Interface Translation"
Actual Results:
# Currently user is not able to see saved translation in placeholder text Text via "User Interface Translation"
Please refer attached screenshots for the same.
Looks good to me.
Comment #8
orkutmuratyilmazThanks for fixing it.
Comment #10
matt bThis isn't fixed.... I cannot translate the placeholder in v2.0.1