how to get password field value using javascript? please i help out i am stucked on it since morning

I am using document.getElementById("password").value to recieve the password type input field.

please help out!

the form also has an action="authenticate_signup.php"

it shows as if the password field value is not retrieved.


Check if your element id is defined properly.

It should work as expected, there is no security restriction. You can even switch between input types like: document.getElementById("password").type = 'textbox';

var password = document.getElementById('password');

    alert('No password entered!');

It's this simple. This should work. You probably have some other javascript error that is preventing this code to execute. Try using console in firefox or chrome to see that error.

Need Your Help

Is it possible to draw an Uint8ClampedArray directly to a canvas?

javascript html5 canvas

In JavaScript, you can manipulate pixels of an image directly using an Uint8ClampedArray. Before rendering that image to a canvas, you have to:

Rails - can't connect form to controller action

ruby-on-rails forms model-view-controller ruby-on-rails-4 form-helpers

I need to make a form that sends two hidden fields to a controller. The form is not bound to any specific object, I just need to get the inputs to the controller. Here is my view code: