I have written a form validation using JS which ends with return(true);
function check() { ....validation code return(true); }
All I want i
You should use return true; and your if statement doesn't need the === true comparison.
return true;
=== true
function check() { //validation code return true; } if(check()) { //Another function code }
JSFIDDLE