I need a simple javascript code that I'll put inside the html page and do the following:
When a user enters the page, a popup appears that asks to enter a password.
If the correct password is entered, the user will see the window content.
If the wrong password is inserted, the popup will say: "wrong password, try again"
And if a user hit the "cancel" button,
it will do nothing, and the page will stay blank without content until the user hits the refresh button or the back button to the previous page and will try to enter the "secure" page again,
It doesn't need to be complicated or too secured.
The content of the page that I want to secure is not sensitive.
thanks.
Related
enter image description hereHow to handle Chrome login popup.. I have a Situation where:
-> there is a button, and when it is clicked, it creates an authentication popup; now I can not append username and password to it as URL is dynamic.
-> Also I have to verify whether the pop up is displayed, then have to enter credentials and submit.
I have a loginForm.vb, and 3 user controls: promptEmail.vb, promptLogin.vb, promptEmailRecovery.vb.
When I launch the app I want the Login Form to load the promptLogin.vb by bringing it to front.
Then when I click forgot password which is a button in promptLogin.vb, I want it to load the promptEmailRecovery.vb and hide the prompt login.
How can this be done?
Bring the login prompt to the front in the designer through its context menu there. Then it'll be in front when the form loads.
In the .Click event handler for the forgot password button, Call .BringToFront() on the promptEmailRecovery user control.
tvOS provides a very simple and basic way to login user. Just put some text fields like email and password field and when you press on that I will open a new screen where you can enter first email then press Continue and then you enter the password and then there is a Done button.
I am facing a hard time in figuring out that when done is pressed how can I get the callback for that. So that I start authenticating the user credentials.
I have a login screen where I set the focus to be on the password textbox so that the user can start typing their password without clicking anything.
I want to set the focus to the login button as soon as a character is typed into the password textbox so that the user can just hit Enter when they're done typing in the password.
I don't want to lose focus on the password textbox, but I want the login button to be highlighted so that you can hit Enter.
Right now I have to hit Tab, then Enter for this to work.
Set the Form.Accept Property of your Form to the Button's Name:
Gets or sets the button on the form that is clicked when the user
presses the ENTER key.
Then when the user is done entering their password and hits enter your button will be clicked automatically for them.
Figured it out. Went to the Property Sheet for the Login button and the Default property was set to No. Changed it to Yes and it works perfectly. Thanks.
I am having a requirement that when a user makes his payment and reached on success page and go back it should be redirected to a custom page. So if i will click on browser back button it will show me two options - Leave Page and Stay on this page. When i will click on Leave page it should redirect to my custom page. I found following link useful but not working for 'Leave Page' button....kindly suggest or help.
using onbeforeunload event, url change on selecting stay on this page