Skip to content
This repository has been archived by the owner on Mar 7, 2021. It is now read-only.

Enable the function of Remember Me #2

Closed
wants to merge 3 commits into from

Conversation

yums467
Copy link

@yums467 yums467 commented Jun 10, 2015

image
I achieve the function of "remember me",when user checked the check box(named remember me),next
time,user load (or reload )the web,the username and password will add to the text box automatic.
That is my method to achieve the function:
1.I use the javascript and cookie of browser to achieve the function .
2.I enable the HTML element "remember-me" check box .
3.Modify the login.js, add the responding of check box click,when user checked the check box,set the cookie,un-checked the check box clear the cookie.
4.Add a javascript file :rememberMe.js, this script set,get and check the cookie of the browser.
5.in the responding of submit action(in login.js),add some code to deal with the situation of that
user checked the check box before input the username and password .

1.add a link of javascript .
2.enable the HTML element checkbox  "remember-me",set the id of checkbox as "checkme".
3.call the function in js (checkCookie() a part of the function of RememberMe)  in HTML <Body> onLoad.
1.responding the action of checkbox click,if “checked” set the cookie of the browers,else clear the cookie.
2.modify the submit action,add the test code to  deal with the user operation "checked the checkbox before input the name and password"
the javascript to achieve the set,get and check cookie of browers.
we use the javascript and cookie to achieve the function of Remember Me.
we storage the username and password and the status of checkbox in the cookie
@yums467
Copy link
Author

yums467 commented Jun 10, 2015

maybe we can achieve more function such the Registration

@yums467 yums467 closed this Jun 10, 2015
@yums467 yums467 reopened this Jun 10, 2015
@yums467 yums467 closed this Jun 10, 2015
@yums467 yums467 reopened this Jun 10, 2015
@fethica
Copy link
Collaborator

fethica commented Jun 23, 2015

Thank you for your contribution, I will check your code soon 👍

@helloromero
Copy link

any update on this?

@Lynnstrum Lynnstrum mentioned this pull request Aug 12, 2016
@cenkdominic
Copy link

Has anyone tried this? Does it work?

@codeflight1
Copy link

looks good to me!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants