Some of our users don't understand what "Remember Me" means (I expect it is because "remember me" is often used to save login info like a username or password). We'd like to tweak the text ("Keep me logged in on this computer") but can't do so easily. It'd be nice to have a configurable option for this within the module.

Comments

archimedes created an issue. See original summary.

gapple’s picture

Version: 7.x-1.0-rc1 » 8.x-1.x-dev

That is a really good suggestion.

I'll add it in to the 8.x version, since translatable configuration is really simple, and hopefully someone can help with a patch for 7.x

  • gapple committed d07e918 on 8.x-1.x
    Issue #2763523: Configurable text on login form.
    
gapple’s picture

Version: 8.x-1.x-dev » 7.x-1.x-dev

Committed to 8.x, so setting the issue back to 7.x

jalpesh’s picture

Status: Active » Needs review
StatusFileSize
new3.43 KB

I have try to add same configuration for drupal 7 module.

Let me know my mistake in patch. Thanks.

Status: Needs review » Needs work

The last submitted patch, 5: configurable-text_2763523.patch, failed testing.

jalpesh’s picture

Status: Needs work » Needs review
StatusFileSize
new3.38 KB

Here we go with new patch, change in label name to make consistence D8 module label.

Status: Needs review » Needs work

The last submitted patch, 7: configurable-text_2763523_2.patch, failed testing.

gapple’s picture

Thanks for the patch. It's a good start, but t() should only be used for translating static strings.

It's been a while since I've worked with a multilingual site, so I'll have to look more into the right way to enable translation of user-configurable interface text.

jalpesh’s picture

Yup, you are right. we should not use t() tag to translating variable as mention in https://api.drupal.org/api/drupal/includes%21bootstrap.inc/function/t/7.x. I think the patch is failing because of following line in patch.

'#title' => t(variable_get('persistent_login_remember_label', PERSISTENT_LOGIN_REMEMBER_LABEL))

I will try to find out other solution. Thanks.

gapple’s picture

The testing failure was just due to there not yet being any tests to run, so I've disabled automated tests.

kapil.ropalekar’s picture

Status: Needs work » Needs review
StatusFileSize
new4.81 KB
new10.56 KB
new7.15 KB

Hi gapple,

I have created a patch and tested the "Remember me" text to be translatable on a multi_lingual instance.

The configuration text-field for "Remember me" under admin/config/system/persistent_login has been added as Form Label. I feel that we should keep this field required so that blank value validation will be taken care of.

Also added the variable_del under the uninstall hook.

Attached are a few screenshots for your reference where i tired testing the "Remember me" text on the user login page for the Languages Japanese and France.

Could you kindly test the patch and let me know your reviews.

Thanks !

jalpesh’s picture

Thank @kapil.ropalekar for patch.

I hope that you have also take care of https://www.drupal.org/node/2766223 in your patch as it was already committed to 8.x branch.

archimedes’s picture

Thanks for the work, everyone! Any more movement on this? What's next? I'd love to get this into our site soon.

nitesh sethia’s picture

StatusFileSize
new4.44 KB

Fixing the Indentation issue and Moving the form label change configuration of the top of the configuration page.

gapple’s picture

Status: Needs review » Needs work

None of the patches have addressed that t() should only be used for translating static strings, as was mentioned in comment #9

somnolentsurfer’s picture

Did this never make it back into Drupal 7? I'm trying to eliminate the need for an EU cookie popup on our site and I think the login cookie is that last thing. If I could just get it to say something like 'Remember me with a cookie' I could turn the popup off.

gapple’s picture

@somnolentsurfer you can implement a form_alter to adjust the text as needed for your site, but it is currently not possible through the UI.

The persistent login cookie is functionally and technically equivalent to the session cookie, so would it actually require any different or additional notification?

gapple’s picture

Version: 7.x-1.x-dev » 8.x-1.x-dev
Status: Needs work » Fixed

Closing out 7.x issues.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.