Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I'm concerned that the translations for the login errors are being forced to include html that is unnecessary and difficult to deal with by translation software. I've included a patch that should clean this up by separating out both strings.
Comment | File | Size | Author |
---|---|---|---|
#2 | invalid-login-separate-translations-non-html-2270611_2.patch | 1.11 KB | generalconsensus |
Comments
Comment #1
generalconsensus CreditAttribution: generalconsensus commentedComment #2
generalconsensus CreditAttribution: generalconsensus commentedIgnore the first patch, this patch makes the form error consistent with the default drupal form validation error. This will cause the translations to be used by default.
Comment #3
Jerenus CreditAttribution: Jerenus commentedHi generalconsensus,
The patch does't work.
# patch -p1 < invalid-login-separate-translations-non-html-2270611_2.patch
patching file commerce_extra_login_page.panes.inc
Hunk #1 FAILED at 151.
1 out of 1 hunk FAILED -- saving rejects to file commerce_extra_login_page.panes.inc.rej
Thanks,
Jerenus
Comment #4
5n00py CreditAttribution: 5n00py commentedSee https://www.drupal.org/node/322774 , here is some info about using html in t() function.
I see that your patch have modification in source string ("email" replaced with "username"), but this is another issue.
If you have problem with this, you can create another issue.