开发者

Prevent Rails from caching a password

开发者 https://www.devze.com 2023-01-08 03:12 出处:网络
I\'m setting up an edit profile page. And the password is available for change on it. The only problem is that the password_field gets prepopulated with the password, and when they just want to chang

I'm setting up an edit profile page. And the password is available for change on it.

The only problem is that the password_field gets prepopulated with the password, and when they just want to change their name, they must 开发者_JAVA技巧also change their password as well.

Does anyone know a common workaround to this?


Can I assume this is about a profile page on a web page and that you can set any attribute? I'm not a Rails programmer, but in HTML, this is all it takes (the autocomplete attribute):

<input type="password" autocomplete="off" value="">

If you have that in place, browsers will not autofill or remember the passwords.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号