+ 3
How to get the value from textboxes?
i have created login page I don't know how to get entered value from the textboxes https://code.sololearn.com/W17WX4Z8s85g/?ref=app
5 Réponses
+ 6
Your code was fine for the most part, but if you're going to use [] you need to surround the form name and id's passed in quotes (see commented code below). Otherwise, just use dot notation instead. Also, I added some <br> tags for better readability of the output.
function disp()
{
//var a=document.forms["f1"]["e1"].value;
var a=document.forms.f1.e1.value;
var b=document.forms.f1.p1.value;
document.write("Your mail id is: " + a + "<br>");
document.write("Your password is: " + b + "<br>");
document.write("Do you like this code <br /> Give one thumbs up👍")
}
+ 4
Thank you 😊@chaoticDawg
+ 3
Thanks @Aditya Maddheshiya
sure i will start to learn JavaScript & Php
+ 2
you need to learn php and javascript
+ 2
Now run my code @ChaoticDawg
all credits goes to you🎊🎉
https://code.sololearn.com/W17WX4Z8s85g/?ref=app