in some case u r using var = in funtions, and some cases u r direct getting to getelementbyid, no var is attached how to understand where to go ahead with var copy by vaLUE nd copy by referece part its confusing
I copied all of your code into visualstudio code, with index.html and message. The javascript alert works fine, if nothing is entered and press submit, but if I enter a username and password and press submit, it doesn't go to message, I'm on windows 10.
45 responses to “#26 Form Validations in JavaScript”
Please source code …….
In description or other upload..
Hi sir,This JS & Jquery was help me.and i want learn PHP object oriented programming with mysql,is there any vieos in channel
How to achive full validation..any vidio in this channel..
Superb explanation…
Thank you <3
Nice video :)))
thanks bro
'over yor'
Sir very nice videos, but I have a confusion why didn't u write like "return true; " in else part. Without return keyword, how its working.?
in some case u r using var = in funtions, and some cases u r direct getting to getelementbyid, no var is attached how to understand where to go ahead with var copy by vaLUE nd copy by referece part its confusing
This vedio is very good for devaloper feelds
Amazing explanation I am from Pakistan
Wouldn't that trim method also trim out besides spaces?
I learned something today. Thanks
code is not executing plz help me sir …..
Teaching style awesome bro
Proud of video clarity
Amazing clear explanation
Ap thora slow work kia krain ar cursor ko highlighted condition mn rakhin taky sabhi log smjh skain asani se
If have new videos Please put your text code in descriptions
Calling the function either in button tag or in form tag has no much difference right? Execution happens on same time. isnt it?
Thanks It Helped me for Quick Revision
You explain how to do this very well.
After I saw this video I got little idea about this validate tq sir
I copied all of your code into visualstudio code, with index.html and message. The javascript alert works fine, if nothing is entered and press submit, but if I enter a username and password and press submit, it doesn't go to message, I'm on windows 10.
What would happen if the form will have more than 2 input boxes ?
I mean how should I write it?useing while loop statements?🤔
best explanations
Delivering the best content as always…thank you Telusko!!!!!!!
provide the file link in DESCRIPTION for easy learning 😉
Hello sir.. which application is you are used in these video. It's quite easy and comfortable interface for new programmer's.
you didn't reply me.
Tanmay please solve my problem
after solve the problem.Tell me guys where was the problem. Again i will remember it.
I'm confused. how i can solve these errors
This form is not working. How can solve errors in this form
<html>
<head>
<title>Form validation</title>
</head>
<body>
<form onsubmit="return getvalidate()" >
<input id="name" placeholder="Enter name"/><br/>
<input id="pass" placeholder="Enter password"/><br/>
<button type="submit">Submit</button>
</form>
</body>
<script type="text/javascript">
function getvalidate(){
name=document.getElementById("name").value;
pass=documetn.getElementById("pass").value;
if(name==""){
alert('Fill the name');
name.style.border="1px solid red;"
return false;
}
else if(pass==""){
alert('Fill the password');
pass.style.border="1px solid red";
return false;
}
else{
return true;
}
}
</script>
</html>
SPIK INGLIŠ
Your explanations are really amazing.
how do i make the button to be disabled if either textbox is empty?? i know in csharp you use something like btn1.enabled == false;
amazing… i am beginner but got everything u explained
How can i combine form validation and Regular expression in one form ??
Nice and to the point. Thanks man!!
Thanks Tanmaya…
have you ever across a scenario where onsubmit attribute doesn't work?
Clear explanation, thank you
thanks bro..