Topic on Project:Support desk

Jump to navigation Jump to search

How do I set the "remember me" checkbox to "checked" by default?

5
Tenbergen (talkcontribs)

I would like our users to remain logged, so would like the "remember me" checkbox set by default. I found an article that describes using a hook to do this (https://webmasters.stackexchange.com/questions/79907/how-to-set-the-keep-me-logged-in-box-to-true-in-mediawiki-specialuserlogin/80941). It seemed hacky, but since I could not find a config setting to do this, I tried it. It actually works OK, except I now get an exception when I try to create a new user. Is there a proper way to set this box to "checked" by default? Thanks!

Ammarpad (talkcontribs)

This code should do want you want. I moved it there because this flow board cannot even format code properly.

Tenbergen (talkcontribs)

Thank you Ammarpad, that does the trick, and the account creation page works with this one. Will you maintain the answer at your sandbox or should I copy it into a subpage of my user page? Or is there a more appropriate place to document this?

Ammarpad (talkcontribs)

You can copy and reuse it anywhere per the usual mediawiki.org license. I don't know any appropriate documentation to add it now, if you happen to know one, you can add it (with appropriate caveat for hacks).

Ciencia Al Poder (talkcontribs)
Reply to "How do I set the "remember me" checkbox to "checked" by default?"